Previous Topic: Verify CompletionNext Topic: Results of DDL Generation


Generate a DDL

This procedure explains how to select database component objects for DDL generation. During the selection process, you can enable the generation options (DDL generation, include DROP statements, or install) in these ways:

You may find it useful to enable the desired code generation options as you go.

  1. Start the Construction Client.
  2. Open a model by selecting Model.
  3. Select Actions, then Open in the Construction Model Selection window.
  4. Highlight a model from the list and select OK.
  5. Select DDL, then Generate.
  6. Select Edit, then Select New Objects.

    This displays the database component object type list.

    You can select one or more objects at a time. The client automatically flows to the next object type when you select more than one.

  7. Select Database and select List.

    This action displays the DDL Generation Object Type Occurrence List.

  8. Select one or more databases and select Add. Select a database and select Expand. (You can also select Continue to return to the object type list.)

    The expansion displays a list of tablespaces in the DDL Generation Expanded Object Occurrence list.

    If you want to generate all components in a database automatically, without having to manually select them, mark the Apply to All Subordinates generation option.

  9. Select one or more tablespaces and then select Add. Select one tablespace and then select Expand.

    These two actions add the tablespaces to the generation list and expand to the next subordinate level for the selected tablespace.

    If you want to generate all components in a tablespace automatically, without having to manually select them, mark the Apply to All Subordinates generation option.

  10. Select one or more data tables from the list and then select Add. Select one data table from the list and select Expand.

    If you want to generate all components in a data table automatically, without having to manually select them, mark the Apply to All Subordinates generation option.

  11. Select one or more indexspaces from the list and then select Add. There is no expansion beyond this level.
  12. Select Continue until you return to the list of tablespaces. Select the next tablespace if you are generating more than one in this database. Perform the steps to add that tablespace and all of its subordinate objects to the list.
  13. Select Continue until you return to the DDL Generation window.
  14. Select the appropriate generation flags for all desired components and then select Generate, then Flagged.

You can use the steps in this procedure to generate the entire DDL or to perform selective regeneration on changed components. When generating the entire database, it is better to use the Model option found in the Generate menu. For more information, see Select a Generation Action.