Generating DDL for Database Objects - Teradata Studio

Teradata Studio IDE Plug-in User Guide

Product
Teradata Studio
Release Number
16.00
Published
March 2017
Language
English (United States)
Last Update
2018-05-03
dita:mapPath
poj1484765174891.ditamap
dita:ditavalPath
ft:empty
dita:id
B035-2043
Product Category
Teradata Tools and Utilities
The Generate DDL wizard generates the SQL CREATE and DROP statements for databases and database objects. You can save the SQL to a script file, and execute the DDL script from the SQL Editor.

For Aster systems, this only applies to Aster 6.10 and later.

  1. In the Data Source Explorer, click to select one or more of the same type of database object. .
  2. Right-click one of the selected objects and click database_type > Generate DDL, where database_type is the type of database for the current connection profile, for example, Teradata or Aster. The Objects dialog of the Generate DDL wizard opens.
  3. Select the types of DDL statements you want to generate for the selected objects, and click Next.
  4. Select the classes of objects for which the DDL will be generated, and click Next. The object definitions you are able to generate depend on the type of object you selected in Data Source Explorer. The wizard generates the DDL and displays the resulting script in the Save DDL page.
  5. Use the Folder and File Name fields to specify where you want the wizard to save the generated script. The default is the SQL folder displayed in the Project Explorer. Click Browse to specify a different folder.
  6. Review the generated DDL script in the Preview DDL area.
  7. [Optional] Select the Open DDL file for Editing check box to open this SQL file in an SQL Editor when you click Finish.
  8. Click Next.
  9. Review the Summary of selections you made in previous steps. To make changes, click Back to return to a previous panel of the wizard and make your change.
  10. Click Finish. The script file is saved to the location and file name you specified, and appears in the Project Explorer view. If you chose to open the DDL file for editing, the generated DDL displays in the SQL Editor where you can edit it and save or execute the edited DDL.