Rational Developer for System z
COBOL for Windows, Version 7.5, Language Reference


Appendix B. Compiler limits

The following table lists the compiler limits for programs and class definitions.

Table 58. Compiler limits
Language element Compiler limit
Maximum length of user-defined words (for example, data-name, file-name, class-name) 30 bytes
Size of program 999,999 lines
Maximum file record size 64K
Number of literals 4,194,303
Total length of literals 4,194,303 bytes
Reserved word table entries 1536
COPY REPLACING . . . BY . . . (items per COPY statement) No limit
Number of COPY libraries No limit
Block size of COPY library 32,767 bytes
Identification division
Environment division
Configuration section
Special-names paragraph
mnemonic-name IS 18
UPSI-n . . . (switches) 0-7
alphabet-name IS . . . No limit
Literal THRU . . . or ALSO . . . 256
Input-Output section
File-control paragraph
SELECT file-name . . . A maximum of 65,535 file names can be assigned external names
ASSIGN system-name . . . No limit
ALTERNATE RECORD KEY data-name . . . 253
RECORD KEY length No limit
RESERVE integer (buffers) 255
I-O-control paragraph
RERUN ON system-name . . . 32,767
RERUN integer RECORDS 16,777,215
SAME RECORD AREA 255
SAME RECORD AREA FOR file-name . . . 255
SAME SORT/MERGE AREA No limit
MULTIPLE FILE file-name . . . No limit
Data division
77 data item size 2,147,483,646 bytes
01-49 data item size 2,147,483,646 bytes
Total 01 + 77 (data items) No limit
88 condition-names . . . No limit
VALUE literal . . . No limit
66 RENAMES . . . No limit
PICTURE clause, number of characters in character-string 50
PICTURE clause, numeric item digit positions If the ARITH(COMPAT) compiler option is in effect: 18

If the ARITH(EXTEND) compiler option is in effect: 31

PICTURE clause, numeric-edited character positions 249
Picture symbol replication ( ) 2,147,483,646
Picture symbol replication (editing) 32,767
Picture symbol replication ( ), class DBCS items 1,073,741,823
Picture symbol replication ( ), class national items 1,073,741,823
Group item size: file section 1,048,575 bytes
Elementary item size 2,147,483,646 bytes
VALUE initialization (total length of all value literals) 2,147,483,646 bytes
OCCURS integer 2,147,483,646
Total number of ODOs 4,194,303
Table size 2,147,483,646 bytes
Table element size 2,147,483,646 bytes
ASCENDING or DESCENDING KEY . . . (per OCCURS clause) 12 KEYS
Total length of keys (per OCCURS clause) 256 bytes
INDEXED BY . . . (index names per OCCURS clause) 12
Total number of indexes (index names) per class or program 65,535
Size of relative index 32,765
File section
FD file-name . . . 65,535
LABEL data-name . . . (if no optional clauses) 255
Label record length 80 bytes
DATA RECORD data-name . . . No limit
BLOCK CONTAINS integer 1,048,575
RECORD CONTAINS integer 1,048,575
Item length 1,048,575 bytes
LINAGE clause values 99,999,999
SD file-name . . . 65,535
DATA RECORD data-name . . . No limit
Sort record length 32,751 bytes
Linkage section
Total size 2,147,483,646 bytes
Local-storage section
Total size 2,147,483,646 bytes
Working-storage section
Total size of items without the external attribute 2,147,483,646 bytes
Total size of items with the external attribute 2,147,483,646 bytes
Procedure division
Procedure and constant area 4,194,303 bytes
Procedure division USING identifier . . . 32,767
Procedure-names 1,048,575
Subscripted data-names per statement 32,767
Verbs per line (TEST) 7
ADD identifier . . . No limit
ALTER procedure-name-1 TO procedure-name-2 . . . 4,194,303
CALL . . . BY CONTENT identifier 2,147,483,647 bytes
CALL identifier or literal USING identifier or literal . . . 500
CALL literal . . . 4,194,303
Active programs in a run unit 32,767
Number of names called (DYN option) No limit
CANCEL identifier or literal . . . No limit
CLOSE file-name . . . No limit
COMPUTE identifier . . . No limit
DISPLAY identifier or literal  . . . No limit
DIVIDE identifier . . . No limit
ENTRY USING identifier or literal . . . No limit
EVALUATE . . . subjects 64
EVALUATE . . . WHEN clauses 256
GO procedure-name . . . DEPENDING 255
INSPECT TALLYING and REPLACING clauses No limit
MERGE file-name ASC or DES KEY . . . No limit
Total merge key length 4,092 bytes
MERGE USING file-name . . . 16
MOVE identifier or literal TO identifier . . . No limit
MULTIPLY identifier . . . No limit
OPEN file-name . . . No limit
PERFORM 4,194,303
SEARCH . . . WHEN . . . No limit
SET index or identifier . . . TO No limit
SET index . . . UP/DOWN No limit
SORT file-name ASC or DES KEY No limit
Total sort key length 4,092 bytes
SORT USING file-name . . . 16
STRING identifier . . . No limit
STRING DELIMITED identifier or literal . . . No limit
UNSTRING DELIMITED identifier or literal  . . . 255
UNSTRING INTO identifier or literal . . . No limit
USE . . . ON file-name . . . No limit

Terms of use | Feedback

Copyright IBM Corporation 1996, 2008.
This information center is powered by Eclipse technology. (http://www.eclipse.org)