Home

 

Generating DDL from physical data model and deploy

In this section, we generate the DDL and run the generated DDL into the Derby database:

In the Data Project Explorer, right-click the schema (Data Models Æ Bank_model.dbm Æ Database) RAD75Bank Æ Generate DDL.

In the Generate DDL dialog, select Fully qualified name and CREATE statements (Figure | 1-38), and click Next.

Figure 11-38 Generate DDL

In the Objects page, leave everything selected and click Next.

In the Save and Run DDL page, change the file name to rad75bank.sql, review the DDL, select Run DDL on server, and click Next (Figure | 1-39).

Figure 11-39 Save and Run DDL

In the Select connection page, select ITSOBANKDerby, and click Next.

In the Summary page, click Finish.

The SQL script is created and stored in the SQL Scripts folder. Open rad75bank.sql to review the DDL.

In the Database Explorer right-click the ITSOBank connection and select Refresh. You can see RAD75BANK schema is displayed.

Tip: If you cannot see the RAD75BANK schema, you can right-click Schemas Æ Properties and make sure both ITSO and RAD75BANK are selected. The RAD75BANK schema with two tables is now visible.

ibm.com/redbooks