COBOL Manual for TNS and TNS/R Programs

Environment Division
HP COBOL Manual for TNS and TNS/R Programs522555-006
6-40
FILE-CONTROL Paragraph
FILE STATUS clause
defines filestat as the file-status data item for the file. When a COBOL run-
time I-O routine completes an operation on the file, it stores the status code in
filestat before returning control to your program (see I-O Status Code).
filestat
is a 2-character alphanumeric, nonnational data item defined in the Working-
Storage Section, Extended-Storage Section, or Linkage Section.
File-Control Entries for Relative Files
Relative organization provides the capability to read records from or write records to a
disk file either randomly or sequentially. For each record in a relative file, a positive
integer value that specifies the record’s logical ordinal position in the file uniquely
identifies the record. In HP COBOL you can also use alternate alphanumeric or
unsigned numeric keys (with possible duplicate values) within each record. A relative
file has a fixed maximum record length, but the records can be of various lengths up to
that maximum. A file-control entry for a relative file includes an ORGANIZATION
RELATIVE clause.
STATUS
ISFILE
filestat
VST046.vsd
.SELECT clause ASSIGN clause
RESERVE clause
ORGANIZATION clause
ACCESS MODE clause
ALTERNATE RECORD KEY clause
FILE STATUS clause
VST047.vsd