Format 1

Format 1 is used for data description entries in all Data Division sections. Level-number in this format can be any number from 01-49, as well as 77.

Data Description Entry - General Format 1

Read syntax diagramSkip visual syntax diagramlevel-numberdata-name-1FILLER1REDEFINESdata-name-2LIKE2data-name-3(integer)ISTYPEDEF2ISEXTERNALBLANKWHENZEROFORMAT ClauseISGLOBALJUSTJUSTIFIEDRIGHT3OCCURS clause - Format 1OCCURS clause - Format 2PICTUREPICIScharacter-stringSIZE and LOCALE PhrasesSIGNISLEADINGTRAILINGSEPARATECHARACTERVALUEISliteralSYNCHRONIZEDSYNCLEFT3RIGHT3TYPE2type-name-1USAGEISBINARYCOMPUTATIONALCOMPCOMPUTATIONAL-12COMP-12COMPUTATIONAL-22COMP-22COMPUTATIONAL-32COMP-32COMPUTATIONAL-42COMP-42COMPUTATIONAL-52COMP-52DISPLAYDISPLAY-12INDEXNATIONALPACKED-DECIMALPOINTER2PROCEDURE-POINTER2
Notes:
  • 1 Cannot be used with the TYPEDEF clause.
  • 2 IBM® Extension
  • 3 Syntax-checked only

Data Description Entry - General Format 1 (continued)

Read syntax diagramSkip visual syntax diagram
OCCURS clause - Format 1
Read syntax diagramSkip visual syntax diagramOCCURSinteger-2TIMES key-indexed-by phrase
OCCURS clause - Format 2
Read syntax diagramSkip visual syntax diagramOCCURSinteger-1TO integer-2TIMESDEPENDINGON data-name-1key-indexed-by phrase
key-indexed-by phrase
Read syntax diagramSkip visual syntax diagramASCENDING1DESCENDING1KEYISdata-name-2INDEXEDBYindex-name-1
Size and Locale Phrases
Read syntax diagramSkip visual syntax diagramSIZE2ISinteger-3 LOCALEISmnemonic-name-1
FORMAT Clause
Read syntax diagramSkip visual syntax diagramFORMAT2OF DATETIMETIMESTAMP ISliteral-2phrase 1phrase 2
phrase 1
Read syntax diagramSkip visual syntax diagramSIZEISinteger-4 LOCALEISmnemonic-name-2
phrase 2
Read syntax diagramSkip visual syntax diagramSIZEISinteger-5 LOCALEISmnemonic-name-3
Notes:
  • 1 Cannot be used with boolean data type
  • 2 IBM Extension
The clauses may be written in any order with three exceptions:
  • If data-name or FILLER is specified, it must immediately follow the level-number.
  • When specified, the REDEFINES clause must be the first entry following data-name-1 or FILLER. If data-name-1 or FILLER is not specified, the REDEFINES clause must be the first entry following the level-number. The data item being described is treated as though FILLER has been specified.
  • When specified, the TYPEDEF clause must be the first entry following data-name-1. The TYPEDEF clause cannot be specified with FILLER. The TYPEDEF clause and the REDEFINES clause cannot both be specified for data-name-1.

Not all clauses are compatible with each other. For details, see the descriptions of the individual clauses.

Clauses must be separated by a space, a separator comma, or a separator semicolon.