Definitions and Records
Data Definition Language (DDL) Reference Manual — 426798-002
5- 12
RECORD Statement
RECORD Statement
The RECORD statement defines a disk file record; specifies the record’s file name and
type; and if the file is structured, identifies the key fields and assigns a key specifier to
any alternate keys.
If a dictionary is open, DDL stores the record in the dictionary. If a record of the same
name already exists, DDL replaces the existing record with the new record.
Depending on which source files are open, DDL writes the record to a DDL source file;
writes source code to describe the record to a host-language source file; and writes the
file creation commands to a FUP source file.
Parts of the RECORD Statement
A RECORD statement, like a group DEFINITION statement, is a compound statement
composed of a number of simple statements and terminated by END. A RECORD
statement consists of four parts:
Record name
Assigns the record a unique name.
File creation
Assigns the record to a file and specifies file creation attributes (optional part).
Record structure
Defines the record structure specifically or by referring to an existing definition.
Key assignment
Specifies one or more fields within the record as key fields (optional part).
The following syntax summarizes the record structure part of the RECORD statement,
with brief descriptions of the record structure clauses, most of which specify record
attributes.
Section 6, Definition Attributes
, gives complete syntax, descriptions, and
guidelines for record structure clauses.
You can specify record structure clauses in any order for a field or group, with these
exceptions:
•
The level 66 RENAMES clause must follow all field and group descriptions in the
record structure.
•
Any level 88 condition-name clauses and level 89 enumeration clauses must follow
the definition attribute clauses in a field description.