SQL Editor


When you define Selection Criteria, the choices you make will automatically create the SQL required for selecting your data. The generated SQL is displayed in the SQL window of the Selection Criteria section of the Request. If, however, you want to create or edit the SQL yourself, rather than using the SQL automatically created by making selection criteria choices, you can click the Edit SQL icon (image2021-3-11_17-43-49.png) to open the SQL editor.

Warning

Important

If you manually edit and save your SQL, you can no longer go back and continue to use automated selection criteria. However, if you have not yet saved your manually created SQL, you can click the Undo SQL icon (image2021-3-11_17-45-30.png) and return to the Selection Criteria section of the Request.

If you are not already at the File-AID Data Editor Request for a DB2 Object dialog, see Opening-the-File-AID-Data-Editor and Accessing-DB2-Data for information on how to start the File-AID Data Editor.

To edit your SQL manually

1. Optionally, make any automated selection criteria choices as described in Edit DB2 Selection Criteria.

Warning

Important

You can begin by using automated selection criteria then making minor edits manually, or you can skip automated selection criteria and go directly to the manual SQL editor.

2. Click the Edit SQL icon (image2021-3-11_17-43-49.png), then click Yes on the confirmation message. This opens the SQL Editor.
3. Enter your SQL as desired.

Warning

Important

File-AID Data Editor does not support SQL that contains UNIONS, JOINS, Correlation Names, or Special Functions.

4. Optionally, click the Select Columns icon (image2021-3-11_17-47-16.png). The Select column dialog box appears. Select the desired column(s) and click OK. The selected columns are added to the SQL.
5. If you have not yet saved your edited SQL, you can click the Undo SQL icon (image2021-3-11_17-48-6.png) to discard your changes and return to the Selection Criteria section of the Request.
6. Optionally, to save your edited SQL, click Save. This will disable any further use of automated selection criteria for this saved Request.

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*

BMC Compuware Topaz Workbench 20.10