How do I generate an SQL CREATE from an existing Datacom table?

Document ID : KB000022702
Last Modified Date : 14/02/2018
Show Technical Document Details

Question:

I would like to generate the SQL CREATE against an existing Datacom table. What is the easiest way?

Answer:

The CA Datacom Datadictionary batch utility DDTRSLM provides several functions, one of which is EXPORT TABLE. For Datacom tables that are "SQL-able", the EXPORT TABLE function can generate the SQL CREATE statement.

To see an example of the generated output, please refer to the CA Datacom/DB Datadictionary Batch Reference Guide, in the section "DDTRSLM - Transporting Definitions." You will see examples, with the generated CREATE TABLE SQL statements imbedded in the output between the %DDLSTART and %DDLEND statements.

Additional Information:

Refer to the CA Datacom/DB Datadictionary Batch Reference Guide

https://support.ca.com/cadocs/7/CA%20Datacom%20DB%2014%200-ENU/Bookshelf_Files/PDF/DatacomDD14--Batch_Ref_ENU.pdf