View previous topic :: View next topic |
Author |
Message |
arvibala Beginner
Joined: 12 Feb 2008 Posts: 142 Topics: 67
|
Posted: Wed Nov 03, 2010 11:43 am Post subject: SOC7 Abend while calling a module |
|
|
Hi
When our Module is run, we are getting SOC7 abend for second record. To confirm its not data issue, I swapped the records and ran still it abends for the second record.
Code: |
" a data exception (System Completion Code=0C7).
STYHIVFD at entry point STYHIVFD at compile unit offset +00001DB4"
|
This is how I call the module in STTBD110
Code: |
"
INITIALIZE XSTYIVFD-COMM
MOVE TRAN-DTL-SEC-SYS-ID TO XSTYIVFD-SEC-SYS-ID
MOVE TRAN-DTL-ACCT-SYS-ID TO XSTYIVFD-ACCT-SYS-ID
MOVE TRAN-DTL-W9-CERT TO XSTYIVFD-SS-CERT
MOVE TRAN-DTL-W8-SOLICIT-YR TO XSTYIVFD-W8-SOLICIT-YR
MOVE TRAN-DTL-GEO-CD TO XSTYIVFD-GEO-CD
XSTYIVFD-TAX-GEO-CD
CALL WS-STYHIVFD USING XSTY0000-COMMON-ERR-PARM
XSTYIVFD-COMM
"
|
Inside 'STYHIVFD' we are getting the SOC7 abend between 'END-PERFORM' and '2300-EXIT'
Code: |
PERFORM VARYING WS-SUB1 FROM 1 BY 1
UNTIL WS-SUB1 > XSTYIW8C-REC-CNTR -> I suspect some issue here
OR LOOK-UP-STOP
....................
....................
....................
....................
....................
END-PERFORM
.
2300-EXIT.
|
Any help? _________________ Arvind
"You can make a difference with your smile. Have that with you always" |
|
Back to top |
|
|
kolusu Site Admin
Joined: 26 Nov 2002 Posts: 12375 Topics: 75 Location: San Jose
|
|
Back to top |
|
|
dbzTHEdinosauer Supermod
Joined: 20 Oct 2006 Posts: 1411 Topics: 26 Location: germany
|
Posted: Wed Nov 03, 2010 12:12 pm Post subject: |
|
|
Arvind,
go to offset +00001DB4 in program STYHIVFD (look in compile listing)
and see what instruction is being executed.
since it is a SOC7, you know that you have a problem with a numeric field.
thus you comment, Quote: | its not data issue | is not only false,
it is preventing you from solving your problem.
now, it may not be data that you input, but it is still a data issue.
what references are involved with the instruction at offset +00001DB4?
one of those fields contains the bad data value.
and something else that is important to note:
you don't have SOC7's during the CALL to a program,
better title would be
SOC7 in CALLed Program _________________ Dick Brenholtz
American living in Varel, Germany |
|
Back to top |
|
|
papadi Supermod
Joined: 20 Oct 2009 Posts: 594 Topics: 1
|
Posted: Wed Nov 03, 2010 4:11 pm Post subject: |
|
|
Look in the code for a numeric variable that has not been given a "value".
If such a field is added to, subtracted from, etc, or compared to some other numeric value, a 0c7 can happen.
Check to make sure the calling code and the called code have the same definition of the "using" parameters. _________________ All the best,
di |
|
Back to top |
|
|
arvibala Beginner
Joined: 12 Feb 2008 Posts: 142 Topics: 67
|
Posted: Thu Nov 04, 2010 1:13 am Post subject: |
|
|
As I posted before the Abend was between END-PERFORM and 2300-EXIT based on OFFSET value ...
Code: |
001313 001D28 MOVE 001316 001D3C MOVE
001325 001D64 END-PERFORM 001328 001DC6 EXIT
001340 001DD8 SET 001342 001DE4 SET
|
Code: |
001325 END-PERFORM
001326 .
001327
PP 5655-G53 IBM ENTERPRISE COBOL FOR Z/OS 3.3.0 0506 STYHIVFD DATE 09
LINEID PL SL ----+-*A-1-B--+----2----+----3----+----4----+----5----+----6---
001328 2300-EXIT.
|
so I guess the problem is with the PERFORM condition?
UNTIL WS-SUB1 > XSTYIW8C-REC-CNTR _________________ Arvind
"You can make a difference with your smile. Have that with you always" |
|
Back to top |
|
|
arvibala Beginner
Joined: 12 Feb 2008 Posts: 142 Topics: 67
|
Posted: Thu Nov 04, 2010 7:14 am Post subject: |
|
|
I found the issue ... Variable XSTYIW8C-REC-CNTR is not being initialized.
Before the perform a DB2 module STYHIW8C ( only for first record) is being called where this variable is getting initialized. But that call was failing because of -805 (Package Not Found) and we failed to capture that so when the second record was read it directly came to the perform and since it was not initialized ... it failed with SOC7
Thanks All _________________ Arvind
"You can make a difference with your smile. Have that with you always" |
|
Back to top |
|
|
dbzTHEdinosauer Supermod
Joined: 20 Oct 2006 Posts: 1411 Topics: 26 Location: germany
|
Posted: Thu Nov 04, 2010 7:29 am Post subject: |
|
|
apparently, you are not checking sqlcodes.
as you add this very importent logic - checking sqlcodes
you should also add a CALL to DSNTIAR,
this post by JSHARON1248 is an excellent example of implementation. _________________ Dick Brenholtz
American living in Varel, Germany |
|
Back to top |
|
|
arvibala Beginner
Joined: 12 Feb 2008 Posts: 142 Topics: 67
|
Posted: Mon Nov 08, 2010 5:54 am Post subject: |
|
|
Thanks Bren _________________ Arvind
"You can make a difference with your smile. Have that with you always" |
|
Back to top |
|
|
|
|