The ANSI source format divides an input line into several fields. These are determined by character position. Each input line must be 80 characters. Input lines that are shorter than 80 characters are padded with spaces to make 80 characters, while lines longer than 80 characters are truncated on the right. Tab characters are converted into spaces such that the tab stops are eight characters apart.
The ANSI format has five fields. These are:
|Sequence Number Area (columns 1 – 6)||This area is ignored by the compiler and may contain any characters. It is traditionally used for sequence numbers to re-order a scrambled card deck.|
|Indicator Area (column 7)||This column must contain one of the following characters:
|Area A (columns 8 – 11)||Area A contains division headers, section headers, paragraph names, and some level indicators|
|Area B (columns 12 – 72)||Area B contains all other COBOL text.|
|Identification Area (columns 73 – 80)||Any desired text may be placed here. However, the compiler can conditionally compile lines based on patterns found in this area. For details, see Source Code Control.|