Every language sets bounds—how long a name can be, how many digits a number literal accepts, how wide a source line may run before continuation. Easytrieve inherits the eighty-character mainframe record from its era while allowing surprisingly long identifiers compared to COBOL. Beginners hit limits when TITLE text overflows column seventy-two, when packed fields exceed numeric literal precision, or when generated code creates names longer than listing viewers display cleanly. This page catalogs Broadcom documented maximums and the practical limits teams impose below them for maintainability.
| Item | Maximum | Notes |
|---|---|---|
| Field name | 128 characters | Letters, digits, specials except delimiters |
| Label (JOB, PROC, etc.) | 128 characters | Cannot be all numeric |
| Alphanumeric literal | 254 characters | Single-quoted; DBCS/MIXED up to 254 bytes |
| Numeric literal digits | 18 digits | Plus optional sign and one decimal point |
| Source record | 80 characters | Fixed on z/OS source libraries |
| Statement area (default) | Columns 1-72 | Configurable via SCANCOLS/SCANCOLE |
| Hex literal bytes | Half of hex digit count | Each pair = one byte; even digit count required |
Field names and labels share the 128-character ceiling. The first character must be alphabetic, numeric, or national (# @ $). The name cannot be all numeric—that would collide with numeric literal syntax. Delimiters comma, quote, parentheses, and colon cannot appear inside the name. Long names help self-documenting code but wrap in compile listings and ISPF browse sessions. Many shops cap practical names at twenty to forty characters even though the compiler accepts more.
1DEFINE WS-CUSTOMER-ACCOUNT-BALANCE-REMAINING-AFTER-DISCOUNT W 9 N 2
Qualification adds file name, colon, and field name. FILEA:WS-CUSTOMER-... counts each identifier separately toward its own limit; the combined text on one line must still fit the statement area or use continuation.
Report titles, DISPLAY messages, and VALUE clauses may embed long text literals up to 254 characters. Coding them on one line rarely fits columns 1-72—use continuation with minus or plus at line end. Embedded apostrophes double the quote character and consume two columns per apostrophe in source even though the runtime string is one character.
12TITLE 01 'REGIONAL PAYROLL EXCEPTION REPORT - INVALID DEDUCTION CODES -+ CONTACT HR SHARED SERVICES FOR CORRECTIONS'
Numeric literals accept eighteen digits total across integer and fractional parts. Sign prefix and decimal point do not count toward the eighteen digits in Broadcom examples but affect how values map to packed, zoned, and binary fields. Assigning a literal with more precision than field DECIMALS truncates or rounds per field type rules. For currency with two decimal places, literals like 99999999999999.99 approach the practical ceiling.
z/OS source libraries store Easytrieve programs as eighty-character fixed records. Columns seventy-three through eighty traditionally hold sequence numbers for card sorters and audit trails. ISPF displays the full eighty columns; only the statement area is scanned for language syntax. Text beyond SCANCOLE is ignored by compilation but appears on listings— useful for change markers or version tags if your shop allows content there.
Installation options SCANCOLS and SCANCOLE set start and end columns scanned for source. Example: SCANCOLS 7 and SCANCOLE 72 leave columns 1-6 for sequence numbers and 73-80 for identification, matching classic COBOL card layouts. These are compile-time configuration options set in Configuration Manager; individual programs cannot override them. Teams migrating from other tools must verify scan columns match where code was indented historically.
12Columns: 1....6 7.................72 73...80 Content: 001000 DEFINE WS-COUNT W 5 N 0 001000
A 254-character literal assigned to a field defined LENGTH 20 truncates or abends depending on operation. MOVE long literal to short field is a common beginner error. Conversely, short literal MOVE to long field may pad with spaces for alphabetic types. Always match DEFINE LENGTH to file layout and literal size to DISPLAY or TITLE requirements separately.
Hexadecimal literal byte length equals half the count of hex digits inside quotes. X'404040' is three bytes. Mask operations require masks no wider than the target field in bits or bytes per data type. DISPLAY of packed fields with hex masks teaches correct width faster than guessing from decimal literals alone.
Maximum lengths are ruler marks on paper you write on. Names can be very long—128 letters—but the paper line is only eighty boxes wide and only seventy-two count for your sentence. Stickers with words can be 254 letters if you continue on the next line with a plus sign. Numbers can have eighteen digits before the number gets too big for the sticker machine.
1. Field names and labels may be up to:
2. Alphanumeric literals may be up to:
3. Numeric literals support at most:
4. Each Easytrieve source record is:
5. The default statement area spans columns: