Interpreting HLASM source

To process a HLASM copybook, File Manager invokes the HLASM compiler. It then produces a record layout (or segment layout) for each DSECT it finds with corresponding DS or DC fields. File Manager interprets the DS and DC fields as shown here:

Blank field name
If a DS or DC statement does not have a field name, then it is assigned the name "*".
Multiple operands
If a DS or DC statement has multiple operands, then the field isdefined as a group field and a child element is created for each operand with the suffix of "_On" where n is the relative number of the operand.
For example:
REC_TYPE01 DSECT
FIELD1  DS    F,H,CL1
produces:
Ref Field Name                        Picture  Type Start    End Length
    ****  Top of data  ****
  1 1 REC_TYPE01                                AN      1      7      7
  2  2 FIELD1                         F,H,CL1   AN      1      7      7
  3   3 FIELD1_O1                               BI      1      4      4
  4   3 FIELD1_O2                               BI      5      6      2
  5   3 FIELD1_O3                               AN      7      7      1
    ****  End of data  ****
Multiple values
If a DS or DC operand has multiple values associated with it, then a group field is defined with child elements for each value with the suffix of "_Vn" where n is the relative number of the value.
For example:
REC_TYPE01 DSECT
FIELD1  DS    F'1,2,3',H,CL1
produces:
Ref Field Name                   Picture       Type Start    End Length
    ****  Top of data  ****
  1 1 REC_TYPE01                                AN      1     15     15
  2  2 FIELD1                    F'1,2,3',H,CL1 AN      1     15     15
  3   3 FIELD1_O1                               AN      1     12     12
  4    4 FIELD1_O1_V1                           BI      1      4      4
  5    4 FIELD1_O1_V2                           BI      5      8      4
  6    4 FIELD1_O1_V3                           BI      9     12      4
  7   3 FIELD1_O2                               BI     13     14      2
  8   3 FIELD1_O3                               AN     15     15      1
    ****  End of data  ****
Duplication factor
If a DS or DC operand has a duplication factor greater than 1, then the resultant field is treated as a single dimensioned field that occurs the number of times specified by the duplication factor.
For example:
REC_TYPE01 DSECT
FIELD1  DS    5F
produces:
Ref Field Name                                Picture  Type Start    End Length
    ****  Top of data  ****
  1 1 REC_TYPE01                                        AN      1     20     20
  2  2 FIELD1(5)                              F         BI      1      4      4
    ****  End of data  ****
Bit length specification
If a DS or a DC has a bit length specification, it is defined as a bit field irrespective of the field type.
For example:
REC_TYPE01 DSECT
FIELD1  DS    AL.5
produces:
Ref Field Name                                Picture  Type Start    End Length
    ****  Top of data  ****
  1 1 REC_TYPE01                                        AN      1      1      1
  2  2 FIELD1                                 AL.5      BT      1      1      1
    ****  End of data  ****
DSECT or layout length
The level-1 field is always set to the maximum end column for any field.
Redefines/Range specifications
If you are using advanced copybook selection to build a template, the X prefix command enables you to interpret the ORG fieldname in the same manner as a COBOL redefines or PL/I union statement.