ISMCLOSE flushes buffers, unlocks any remaining locks (present due to abnormal termination), and closes the file.
The ISMCLOSE procedure requires the following parameters to return a CLOSE result:
ISMCLOSE (ISAMFILE, CLOSETYPE)
-
ISAMFILE—The user's file.
-
CLOSETYPE—Specifies how the file is to be closed.
Value
Meaning
0,1
Rewind
2
No rewind
3
Save
4
Lock
5
Purge
6
Crunch
If the close result is 1, the close was successful. Other odd-numbered results are errors detected in the ISMCLOSE procedure. These errors are given below. For even-numbered results, refer to the explanation of the CLOSE Results in the File Attributes Programming Reference Manual.
Error Results
Field |
Value |
Meaning |
*[2:1] |
1 |
OPTION was not a valid value. |
*[3:1] |
1 |
File already closed. |