A RTS error 9/004 is
documentation.microfocus.com/.../index.jsp
->
"
COBRT004 Illegal file name (Recoverable)
A file-name contains an illegal character. This could be any character that is not part of the permitted character set or it could be the system-dependent delimiter, which on most systems is the space.
Resolution:
Try the file operation again using the correct file-name.
"
As an example, this sample code snippet will generate a 9/004 on the OPEN OUTPUT statement because the COBOL variable v is equal to spaces ...
...
SELECT optional LS-FILE ASSIGN TO dynamic v
..
WORKING-STORAGE SECTION.
01 v pic x(256) value spaces.
...
PROCEDURE DIVISION.
open output ls-file
I would check variables being used in the COBOL SELECT statement.
Regards
Yvon