Generate the SQL for only selected objects in a map
When you generate the SQL statements for selected
objects in the map, the statements appear in a Run
SQL Scripts window. The statements sent are delimited with semicolons
and have a blank line separating them for readability. The statements in the
Run SQL Scripts window can be saved to a
PC file.
To show the SQL for selected objects in a map:
- In the System i Navigator window, expand the system you want to use.
- Expand Databases.
- Click Database Navigator Maps.
- Double-click the map that you want to work with.
- Click the objects in the map for which you want to
display the SQL that was used to create the object.
- From the Map
menu, select Generate SQL, then select
Selected Objects.
Tips:
- You can also right-click on an object in the Locator pane to generate the SQL.
- When you generate SQL, the default is to open the
generated SQL in the Run SQL Scripts window. If
you want to specify additional criteria before generating the SQL, you can
set the preference to open the Generate SQL
dialog, which also allows you to determine where you want to save the
generated SQL. To change the preference, select User
Preferences from the Options menu, then
select Show properties dialog for generate
SQL.