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

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

book

Article ID: 22702

calendar_today

Updated On:

Products

Datacom DATACOM - AD

Issue/Introduction

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

 

 

 

Resolution

The Datacom Data dictionary 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 Datacom/DB Data dictionary 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.