CPF
CPF0864 End of file in a CL program
Most common cause
RCVF run after the last record, with no MONMSG to catch end of file.
Other causes
- The file is empty, or an OVRDBF sends it to an empty member.
- The program reads the file again after the end without closing and reopening it (CLOSE command).
How to fix it
In the read loop add MONMSG CPF0864 EXEC(LEAVE) right after RCVF.