SiouxCityElvis
Programmer
Can someone explain to me why
runcobol FILLGACH.COB a=TESTACHRECS
causes this to come up?
I am running RMCOBOL-85 on Linux.
PASS-FILENAME:
TESTACHRECS
WS-FILENAME:
TESTACHRECS
COBOL I/O error 30, UNIX error 21 on FILE-ARG-INPUT file /gach/data/.
COBOL I/O error at line 260 in program FILLGACH.COB (/gach/FILLGACH.COB)
Here's my code snippet and my TESTACHRECS exists in a /gach/data/ directory.
So, my display statements show up, which tells me that there is no problem opening the file. The error says line 260(the READ statement line) is where the problem is.
Thanks.
-David
runcobol FILLGACH.COB a=TESTACHRECS
causes this to come up?
I am running RMCOBOL-85 on Linux.
PASS-FILENAME:
TESTACHRECS
WS-FILENAME:
TESTACHRECS
COBOL I/O error 30, UNIX error 21 on FILE-ARG-INPUT file /gach/data/.
COBOL I/O error at line 260 in program FILLGACH.COB (/gach/FILLGACH.COB)
Here's my code snippet and my TESTACHRECS exists in a /gach/data/ directory.
Code:
FILE-CONTROL.
SELECT OPTIONAL FILE-ARG-INPUT ASSIGN TO
WS-FILE-ARGUMENT
ORGANIZATION IS LINE SEQUENTIAL
ACCESS IS SEQUENTIAL.
WORKING-STORAGE SECTION.
...
...
01 WS-FILE-ARGUMENT.
02 WS-FILE-ARG-DIRECTORY PIC X(11)
VALUE "/gach/data/".
02 WS-FILE-ARG-NAME PIC X(30).
PROCEDURE DIVISION USING LINK-ARGUMENT.
...
...
MAIN-PROGRAM.
PERFORM A-100-INITIALIZATION.
MOVE 0 TO ADD-CTR.
PERFORM TEST-INPUT-FILE.
GO TO END-IT.
******************************************************************
A-100-INITIALIZATION.
DISPLAY "PASS-FILENAME: " PASS-FILENAME.
MOVE PASS-FILENAME TO WS-FILE-ARG-NAME.
DISPLAY "WS-FILENAME: " WS-FILE-ARG-NAME.
OPEN INPUT FILE-ARG-INPUT.
OPEN OUTPUT GACHDB-FILE.
******************************************************************
* *
* FILE PROCRESSING CONTROL ROUTINE *
* *
******************************************************************
******************************************************************
TEST-INPUT-FILE.
MOVE "N" TO SW-EOF-ARG-FILE.
PERFORM UNTIL EOF-ARG-FILE
READ FILE-ARG-INPUT NEXT RECORD
AT END
debug DISPLAY "AT END OF FILE"
NOT AT END
PERFORM UNSTRING-REC-FIELDS
PERFORM WRITE-ACHDB-REC
END-READ
END-PERFORM.
...
...
So, my display statements show up, which tells me that there is no problem opening the file. The error says line 260(the READ statement line) is where the problem is.
Thanks.
-David