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

Procedure Division Verbs
HP COBOL Manual for TNS/E Programs520347-003
9-34
CLOSE
CHECKPOINT for Process Pairs
When a requester that is running as a process pair sends a message, and the
backup process takes over before the requester receives a reply, the server can
resend the reply automatically—if a CHECKPOINT statement executes after the
server reads the requesters message but before the server writes a reply (or
generates one automatically with another READ). When this happens, the server
does not see the duplicate message. The CHECKPOINT statement can execute
even if the server is not running as a process pair.
A Process Pair Cannot Update an SQL/MP or SQL/MX Database
An HP COBOL program that runs as a process pair cannot update an SQL/MP or
SQL/MX database.
CLOSE
CLOSE terminates processing of one or more open files or reels of tape. An optional
LOCK phrase prevents the program from reopening the file (unless the file is
dynamically assignable—see #DYNAMIC).
If a file is closed but not locked, the only I-O operation the process can perform on that
file is an open operation. If the file is closed and locked, the process cannot perform
any I-O operation on the file.
CLOSE has these formats:
CLOSE for Sequential and Line Sequential Files
CLOSE for Relative, Indexed, and Queue Files
CLOSE for Sequential and Line Sequential Files
Throughout this topic, “sequential file” means both sequential and line sequential files
unless otherwise noted.
Note. A COBOL program must not modify the contents of a checkpoint list directly. The
execution logic of the routines and the CHECKPOINT statement maintain checkpoint lists
without the need for any other program action.
file-name
CLOSE
file-info
VST138.vsd