View previous topic :: View next topic
|
Author |
Message |
nitin_d
New User
Joined: 27 Oct 2005 Posts: 15 Location: Pune
|
|
|
|
I have a code which reads a file of 200 lines and populates the data in a table(OCCURS 200) in the code.
Code: |
01 WS-ENGFNDTMP-TABLE.
05 WS-ENGFNDTMP-MIN PIC 9(02) VALUE ZEROES.
05 WS-ENGFNDTMP-MAX PIC 9(03) VALUE 200.
05 WS-ENGFNDTMP-DATA OCCURS 200 TIMES
DEPENDING ON WS-ENGFNDTMP-MAX.
|
The code has a logic to read the file till EOF and move the data to the table. This population goes fine until the last record is read. When it returns to read the next record. ideally the FILE STATUS should be 10. However in my case the READ fails with no sysout mesages. The abend message is as follows :
Code: |
CEE0374C CONDITION=CEE3204S TOKEN=00030C84 59C3C5C5 00000000 632
WHILE RUNNING PROGRAM ONDR0250 WHICH STARTS AT 0007EE98
AT THE TIME OF INTERRUPT
PSW 078D1000 C0404040
GPR 0-3 00000BF0 00983170 250F0088 0007FFFC
GPR 4-7 250EC238 8008BA76 250EA100 0007EFFC
GPR 8-B 25B44088 250E8100 250EB100 0008B686
GPR C-F 0007EF94 000BA018 800DE8E0 00000000
CEE0374C CONDITION=CEE3204S TOKEN=00030C84 59C3C5C5 00000000 635
WHILE RUNNING PROGRAM CEEPLPKA
AT THE TIME OF INTERRUPT
PSW 078D2000 8F9C759C
GPR 0-3 000BDB24 000BE380 250EF528 25066578
GPR 4-7 40404040 000B17F0 40404040 000BE47C
GPR 8-B 00000008 000BE488 0F9C7B5F 8F9C6B60
GPR C-F 000B2B40 000BE260 8F9C74A4 0F907BC8
EA995I SYMPTOM DUMP OUTPUT 646
USER COMPLETION CODE=4087 REASON CODE=00000007
|
|
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
1. normallyl an ODO declaration has a min-to-max occurs clause.
2. having the ODO dependency set a max from the get go seems to defeat the purpose of an ODO.
3. you obviously use subscripts, how do you control the value?
4. how many records are in your input file?
5. not knowing your select statement for the file prohibits providing help. Is there a file status clause?
6. if there is a file status clause, do you check it after a read? Do you have code to inhibit a read following an EOF?
7. what sysout message do you expect when a file I/O error occurs? |
|
Back to top |
|
|
nitin_d
New User
Joined: 27 Oct 2005 Posts: 15 Location: Pune
|
|
|
|
Quote: |
you obviously use subscripts, how do you control the value?
|
The subscripts are being controlled by hardcoding the subscript less than = 200
Quote: |
how many records are in your input file?
|
154
Quote: |
not knowing your select statement for the file prohibits providing help. Is there a file status clause?
|
Code: |
SELECT ENGFNDTMP-FILE ASSIGN TO ENGFND
FILE STATUS IS WS-ENGFND-STATUS.
|
Quote: |
if there is a file status clause, do you check it after a read? Do you have code to inhibit a read following an EOF? |
Yes we do check File status for the file and the code has the logic to snap out of the loop when it encountersEOF
Quote: |
what sysout message do you expect when a file I/O error occurs?
|
The sysout message contatins information about file status, the para in which the code fails
Hope my responses help |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
the code has the logic to snap out of the loop when it encountersEOF |
Might the code find a way back into the loop after EOF has been reached?
If you look in the dump, what value is in the subscript?
Does this process have anything to do with Java? |
|
Back to top |
|
|
nitin_d
New User
Joined: 27 Oct 2005 Posts: 15 Location: Pune
|
|
|
|
I have finally resolved this issue. Thanx all for ur time & effort on this.
Did a quick reference on
in the system dump and thus came to know it was a S0C4. Then did a double check in my program where I found the subscript for the array was 9(2) whereas the counter was going beyond 100.
A real silly mistake ... I know
But never the less, your hep is appreciated. |
|
Back to top |
|
|
|