Data Definition Language (DDL) Reference Manual
Definitions and Records
Data Definition Language (DDL) Reference Manual—529431-004
5-6
Group Definition
The TYPE clause for a field within a group DEFINITION statement can refer to a field 
or group definition previously stored in the open dictionary. When a field is defined by 
referring to a group definition, the field effectively becomes a group.
A group’s size is the total of the lengths of its member fields plus any FILLER fields 
generated by the DDL compiler.
Example 5-2. Group Definitions
DEF address.
 03 street-address.
 05 street-no PIC X(8).
 05 street PIC X(12).
 05 apt-no PIC X(4).
 03 city PIC X(14).
 03 state-cd PIC X(2).
 03 zip PIC X(5).
END.
DEF phone. DISPLAY "n<(999) 999-9999>"
 03 area-cd PIC 9(3).
 03 prefix PIC 9(3).
 03 numb PIC 9(4).
END. ! Period is optional
DEF cust-info.
 03 company-name TYPE *
 HEADING "Company".
 03 cust-address TYPE address.
 HEADING "Address".
 03 cust-phone TYPE phone.
 HEADING "Phone".
END.
DEF customer.
 03 cust-name TYPE cust-name.
 03 cust-id PIC 9(6). ! Level number must be < 04
END.










