DDL Compiler Commands
Data Definition Language (DDL) Reference Manual — 426798-002
9- 27
COLUMNS Command
In the next example, the DDL compiler retrieves the record, CUSTOMER, from the
open dictionary, translates it into COBOL source code, and appends the source code
to the open COBOL file:
The record customer is stored in COBSRC as:
?SECTION CUSTOMER,TANDEM
01 CUSTOMER.
02 CUSTNUM PIC X(4).
02 CUSTNAME.
03 LAST-NAME PIC X(12).
03 FIRST-NAME PIC X(8).
03 MIDINIT PIC XX.
02 CUSTADDR.
03 ADDRESS PIC X(22).
03 CITY PIC X(14).
03 STATE PIC X(2).
03 ZIP PIC 9(5).
For the DDL definition of the CUSTOMER record, see the sample database schema in
Appendix B, Sample Schemas
.
COLUMNS Command
The COLUMNS command specifies how many character positions on input lines are
significant for DDL input. Each character position is a column, and you can specify
from 12 to 132 significant input columns.
num
specifies the number of significant one-byte character positions, or columns, for
input;
num
is an integer from 12 to 132.
COLUMNS Command Guidelines
The following points are guidelines for using the COLUMNS command:
•
If you do not specify the COLUMNS command, the default value is
132-character lines.
•
Changing the value of COLUMNS also changes the maximum string length
for DDL.
COLUMNS num
28> DDL
!?DICT $data.sales
!?COBOL $data.sales.cobsrc
!OUTPUT RECORD customer.
!EXIT
Run DDL compiler
Open dictionary
Open COBOL source file
Append customer record
to COBSRC
VST906.vsd
Содержание DDL D40
Страница 36: ...Introduction to DDL Data Definition Language DDL Reference Manual 426798 002 1 14 Examining a Dictionary ...
Страница 66: ...Named Constants Data Definition Language DDL Reference Manual 426798 002 4 10 Standard SPI Constants ...
Страница 230: ...Dictionary Manipulation Statements Data Definition Language DDL Reference Manual 426798 002 8 14 SHOW USE OF Statement ...
Страница 370: ...Dictionary Maintenance Data Definition Language DDL Reference Manual 426798 002 10 24 Converting a Dictionary ...
Страница 456: ...Sample Schemas Data Definition Language DDL Reference Manual 426798 002 B 12 ASSNDDL Statements ...
Страница 470: ...DDL Data Translation Data Definition Language DDL Reference Manual 426798 002 C 14 ...
Страница 528: ...Dictionary Reports Data Definition Language DDL Reference Manual 426798 002 E 8 Requesting Reports ...
Страница 552: ...DDL Alignment Rules Data Definition Language DDL Reference Manual 426798 002 H 4 FIELDALIGN_SHARED8 Alignment Rules ...
Страница 576: ...Index Data Definition Language DDL Reference Manual 426798 002 Index 22 Special Characters ...