COBOL Runtime Error Code – 149 Wrong open mode or access mode for rewri

In this post, you’ll learn about the COBOL runtime Error Code 149 and the reason why you are receiving it

COBOL Error Code :

149

Reason for this Error in COBOL

Wrong open mode or access mode for rewrite/delete (Recoverable) -You are trying to do a REWRITE or a DELETE on a file that you have not opened for I-O, or which is not open at all. -Close the file and reopen for I-O. However, as this error implies that your program logic contains a mistake, you might want to close any open files, execute a STOP RUN statement and then recode.