Common Entries

The following entries are common to all RPG specifications preceding program data in column-limited source (see Fully free-form statements):
  • Positions 1-5 can be used for comments.
  • If it is a free-form statement, positions 6-7 must be blank.
  • If it is a fixed-form statement, the specification type is specified in position 6. The following letter codes can be used:
    Entry
    Specification Type
    H
    Control
    F
    File description
    D
    Definition
    I
    Input
    C
    Calculation
    O
    Output
    P
    Procedure
  • Comment Statements
    • Position 7 contains an asterisk (*). This will denote the line as a comment line regardless of any other entry on the specification. In a free-form calculation specification, you can use // for a comment. Any line on any fixed-form specification that begins with // is considered a comment by the compiler. The // can start in any position provided that positions 6 to the // characters contain blanks.
    • Positions 6 to 80 are blank.
    • See free-form comments for more information about comments in free-form specifications.
  • Positions 7 to 80 are blank and position 6 contains a valid specification. This is a valid line, not a comment, and sequence rules are enforced.