Columns Command - HP DDL D40 Reference Manual

Data definition language
Table of Contents

Advertisement

DDL Compiler Commands
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:
28> DDL
!?DICT $data.sales
!?COBOL $data.sales.cobsrc
!OUTPUT RECORD customer.
!EXIT
The record customer is stored in COBSRC as:
?SECTION CUSTOMER,TANDEM
01 CUSTOMER.
02 CUSTNUM
02 CUSTNAME.
03 LAST-NAME
03 FIRST-NAME
03 MIDINIT
02 CUSTADDR.
03 ADDRESS
03 CITY
03 STATE
03 ZIP
For the DDL definition of the CUSTOMER record, see the sample database schema in
Appendix B, Sample

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.
COLUMNS num
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.
Data Definition Language (DDL) Reference Manual—426798-002
Run DDL compiler
Open dictionary
Open COBOL source file
Append customer record
to COBSRC
Schemas.
9- 27
VST906.vsd
PIC X(4).
PIC X(12).
PIC X(8).
PIC XX.
PIC X(22).
PIC X(14).
PIC X(2).
PIC 9(5).
COLUMNS Command

Advertisement

Table of Contents
loading

Table of Contents