A REWRITE or DELETE statement without the KEY option was run. The last input/output operation on the file was not a READ statement with the SET or INTO option or was a READ statement with the IGNORE option. The ONCODE associated with this message is 1007.
The ERROR condition is raised.
Modify the program so that the REWRITE or DELETE statement is either preceded by a READ statement or, in the case of a REWRITE statement, replaced by a WRITE statement, according to the requirements of the program. A preceding READ statement with the IGNORE option will also cause the message to be issued.
IBM0P7