User guide

Example ENFORM Programs
Dā€“2 058058 Tandem Computers Incorporated
The following program uses the CENTER clause to center ordernum. Notice that the
formatted width ā€œ999ā€, as specified in the dictionary, is used for centering instead of
the value of a field for the report line.
The AS clause formats orderdate, using the mask format and symbol substitution
modifier to substitute X for the 9 symbol.
?DICTIONARY $mkt.dictry
OPEN order;
LIST ordernum CENTER,
orderdate AS "[SS'9X'] M
ZX XX, 19XX
";
Report:
ORDERNUM ORDERDATE
-------- -----------
21 1 10, 1978
25 1 23, 1978
30 2 06, 1978
32 2 17, 1978
35 3 03, 1978
38 3 19, 1978
41 3 27, 1978
45 4 20, 1978
51 6 01, 1978
66 7 09, 1978
122 7 21, 1978
The following program resets the Option Variable @SUBTOTAL-LABEL. The new
value appears in place of the default value asterisk (*).
Three record descriptions are linked, creating new logical record occurrences. The BY
clause groups the records on the value of ordernum. Notice that ordernum requires
qualification, because it appears in both parts and odetail.
The HEADING clause overrides the default quantity heading, creating a narrower
column width in the report.