DDL Compiler Commands
Data Definition Language (DDL) Reference Manual — 426798-002
9- 65
FORTRAN Command
•
FORTRAN does not support unsigned numbers. If you specify an unsigned
number, DDL translates it to a FORTRAN signed integer.
•
For the data types that DDL generates for FORTRAN source code, see
Table C-3
on page C-6.
•
FORTRAN does not accept FILLER fields greater than 255 single-byte characters.
DDL can add filler characters to ensure that structures start on word boundaries; if
such padding generates more than 255 filler characters, DDL breaks them into
smaller fields before writing the FORTRAN source code.
•
The DDL compiler performs all of the syntax checks listed under the FORCHECK
command before writing source output. If the compiler finds a syntax error, it does
not write the source output for the DDL object with the error; it does write source
output for a DDL object if only a warning is issued.
•
DDL ignores the RENAMES clause when generating FORTRAN source output.
FORTRAN Command Example
In the following example, DDL retrieves the definition of the record CUSTOMER from
the open dictionary, translates it into FORTRAN source code, and writes it to the file
\DALLAS.$DATA.SALES.FORSRC. If this file already exists, DDL appends the entry
for CUSTOMER to the file.
For the definition of the CUSTOMER record, see the sample database schema in
Appendix B, Sample Schemas
.
?DICT
?FORTRAN \dallas.$data.sales.forsrc
OUTPUT RECORD customer.
The FORTRAN source code in FORSRC is:
?SECTION CUSTOMER
?PAGE
C Definition CUSTOMER created on 06/11/1987 at 12:55
RECORD CUSTOMER
CHARACTER*4 CUSTNUM
RECORD CUSTNAME
CHARACTER*12 LASTNAME
C Upshift
CHARACTER*8 FIRSTNAME
C Upshift
CHARACTER*2 MIDINIT
C Upshift
END RECORD
RECORD ADDR
CHARACTER*22 ADDRESS
CHARACTER*14 CITY
CHARACTER*2 STATE
CHARACTER*5 ZIP
END RECORD
END RECORD