Page 1 of 1

AIX COBOL Porting

PostPosted: Thu Jul 23, 2009 11:45 am
by gaya3
Hi All,

I have to port COBOL programs from MVS to AIX.
I have issue with the following code:
-----------------------------------------------------------------
SELECT FILECOB ASSIGN TO FILE1.

I have set the value of FILE1 as
export FILE1=/path-where-file-resides/Filename
------------------------------------------------------------------
The above code compiles & link edits without any error.
But during the execution, i get the following message :

IWZ200S Error detected during OPEN for file 'FILECOB'. File status is: 35.
File system indicated: File Not Found.
Message routine called from offset 0x38 of routine iwzWriteERRmsg.
iwzWriteERRmsg called from offset 0x574 of routine _iwzCallUseProc.
_iwzCallUseProc called from offset 0x1538 of routine _iwzSeqOpen.
_iwzSeqOpen called from offset 0x2ec of routine _iwzGenericOpen.
_iwzGenericOpen called from offset 0x458 of routine PGMFILE.
IWZ901S Program exits due to severe or critical error.


Could anyone PLEASE tell me how to correct this error..

Thanks!!

Re: AIX COBOL Porting

PostPosted: Thu Jul 23, 2009 11:24 pm
by dick scherrer
Hello and welcome to the forum,

Talk with your sysadmin and make sure all of the permissions are set correctly.

Re: AIX COBOL Porting

PostPosted: Fri Jul 24, 2009 8:30 am
by gaya3
I am able to access the file if i write the code as
SELECT FILECOB ASSIGN TO FILE1
ORGANIZATION IS LINE SEQUENTIAL.
But i am not able to access the file for SEQUENTIAL files.

May i know what permissions are needed for accessing the SEQUENTIAL files?

Re: AIX COBOL Porting

PostPosted: Fri Jul 24, 2009 10:10 am
by dick scherrer
Hello,

I suspect that if you can read the file as LINE SEQUENTIAL, the path/file permissions allow you at least read access.

Suggest you look in the cobol manual for the release/version of cobol you are using to learn what causes a file status 35 in that environment. This is an input or an output file? If this is an input file, perform an experiment by opening this file as output and see what happens. Use a test file name and not the real file name.

Re: AIX COBOL Porting

PostPosted: Fri Jul 24, 2009 11:48 am
by gaya3
I am working this problem out on the below code.
If i give organization as LINE SEQUENTIAL this code works properly. If I give organization as SEQUENTIAL, I get the below error during Execution.

-------------------------------------------------------------------------------------------------
IWZ200S Error detected during OPEN for file 'STUDENTFILE'. File status is: 35.
File system indicated: File Not Found.
Message routine called from offset 0x38 of routine iwzWriteERRmsg.
iwzWriteERRmsg called from offset 0x574 of routine _iwzCallUseProc.
_iwzCallUseProc called from offset 0x1538 of routine _iwzSeqOpen.
_iwzSeqOpen called from offset 0x2ec of routine _iwzGenericOpen.
_iwzGenericOpen called from offset 0x458 of routine SAMPLEFILE.
IWZ901S Program exits due to severe or critical error.
-------------------------------------------------------------------------------------------------

IDENTIFICATION DIVISION.
PROGRAM-ID. SampleFile.


ENVIRONMENT DIVISION.
INPUT-OUTPUT SECTION.
FILE-CONTROL.
SELECT StudentFile ASSIGN EVFILE1. --------> This has been set outside the program as -- export EVFILE1=<path where StudentFile is present>
* SELECT StudentFile ASSIGN STL-EVFILE1.
* ORGANIZATION IS SEQUENTIAL.
* ORGANIZATION IS LINE SEQUENTIAL.


DATA DIVISION.
FILE SECTION.
FD StudentFile.
01 StudentDetails.
02 StudentId PIC 9(7).
02 StudentName PIC X(10).


PROCEDURE DIVISION.
Begin.
OPEN INPUT StudentFile
READ StudentFile
AT END MOVE HIGH-VALUES TO StudentDetails
END-READ
PERFORM UNTIL StudentDetails = HIGH-VALUES
DISPLAY StudentId SPACE StudentName
READ StudentFile
AT END MOVE HIGH-VALUES TO StudentDetails
END-READ
END-PERFORM
CLOSE StudentFile
STOP RUN.

========================================================

Re: AIX COBOL Porting

PostPosted: Fri Jul 24, 2009 12:03 pm
by gaya3
And when i try to Open the file in INPUT mode, I get the following error during execution..

IWZ200S Error detected during OPEN for file 'STUDENTFILE'. File status is: 95.
File system indicated: Duplicate File Name.
Message routine called from offset 0x38 of routine iwzWriteERRmsg.
iwzWriteERRmsg called from offset 0x574 of routine _iwzCallUseProc.
_iwzCallUseProc called from offset 0x1538 of routine _iwzSeqOpen.
_iwzSeqOpen called from offset 0x2ec of routine _iwzGenericOpen.
_iwzGenericOpen called from offset 0x140 of routine SAMPLEFILE.
IWZ901S Program exits due to severe or critical error.


Please let me know what else i should try out..