COBOL Manual for TNS/E Programs (H06.03+)

Procedure Division Verbs
HP COBOL Manual for TNS/E Programs520347-003
9-35
CLOSE for Sequential and Line Sequential Files
file-name
is the name of the sequential file to be closed.
When more than one file-name appears, the files can have different
organization and access modes and the optional phrases following one file-
name are independent of those following any other file-name.
file-info
UNIT
REEL
specify that the current reel is to be closed and rewound, and a new reel is to
be mounted.
REMOVAL
specifies that the reel of a multiple-reel tape file be rewound and unloaded, and
a new reel is to be mounted.
NO REWIND
specifies that the sequential file is to be left in its current position, not rewound.
LOCK
means the file associated with file-name cannot be opened again during
the current run. If the file is dynamically assignable, the LOCK phrase has no
effect (see #DYNAMIC).
Usage Considerations:
Effects of CLOSE
For each file-name in the CLOSE statement, the run-time routines perform an
appropriate close operation. These close operations occur as if separate CLOSE
statements were executed for each file-name in the order listed. Subsequent
usage considerations describe actions taken during the close operation for one file.
UNIT
REEL FOR REMOVAL
WITH LOCK
NO REWIND
VST139.vsd