VMS Help  —  COBOL  DATA_DIVISION, clauses  RECORD_KEY
  The RECORD KEY clause specifies the Prime Record Key access path to
  indexed file records.

  Format -

   RECORD KEY IS { rec-key | seg-key = {seg}... } [ WITH DUPLICATES ]
                                                     [ ASCENDING ]
                                                     [ DESCENDING]

1  –  rec-key

  is the Record Key for the file. It is the data-name of a data item
  in a record description entry for the file. It can be qualified, but
  it cannot be a group item that contains a variable-occurrence data
  item. The data item must be described as: (1) alphanumeric or
  alphabetic category, (2) a group item, (3) unsigned numeric display,
  (4) a COMP-3 integer, or (5) a COMP integer.

2  –  seg-key

  is the Record Key for the file. It is a segmented-key name that
  represents the concatenation of one or more (up to eight)
  occurrences of seg.

3  –  seg

  is the data-name of a data item in a record description entry for
  the file. It can be qualified, but it cannot be a group item that
  contains a variable-occurrence data item. The data item must be
  described as: (1) alphanumeric or alphabetic category,
  (2) a group item or (3) an unsigned numeric display item.
Close Help