IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Error Handling with OPEN MACRO


IBM Mainframe Forums -> PL/I & Assembler
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2481
Location: Netherlands, Amstelveen

PostPosted: Thu May 31, 2012 2:30 pm
Reply with quote

Ok, good luck.
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2501
Location: Atlanta, Georgia, USA

PostPosted: Thu May 31, 2012 6:07 pm
Reply with quote

Good find, Peter.... icon_smile.gif
Back to top
View user's profile Send private message
Ravi Kuchi

New User


Joined: 29 May 2012
Posts: 14
Location: INDIA

PostPosted: Thu May 31, 2012 7:55 pm
Reply with quote

Hi Friends,

Need one more help for the same module, I want to exit from the error routine gracefully(with return code zero). I have tried lot of options like EXIT,CANCEL,ABTERM etc but was not successful. Any idea/help from you guys is highly appreciated.

At present it throws S013 return code and error message:
IEC141I 013-34,IGG0191A,RSURESHT,STEP0010,INPUT,D827,..

&CSECT AMODE ANY
&CSECT RMODE 24
&CSECT BGNSECT X
DSPLY=YES, X
BASE=(8,9), X
DATE=&DATE, X
V=&VER, X
M=&MOD
L R10,0(0,R1)
USING PARM,R10
MESG 'BEFORE INPUT RAVI'
OPEN (INPUT,(INPUT))
MESG 'AFTER INPUT RAVI'
RETURN
FERROR EQU *
MESG 'INVALID BLOCK SIZE FILE'
SR 15,15
MESG 'INV2'
LH R15,RC
* NEED TO EXIT FROM HERE WITH RETURN CODE ZERO>>
* RETURN
EJECT
EXITMOD EMOD
EJECT
MESG 'IN EXITMOD'
OI RC+1,X'04'
RETURN RC=(15)
ENDSECT
EJECT
MEMBER DS CL8
MSGAREA DS 0CL68
DC CL46' '
INPUT DCB DDNAME=INPUT,DSORG=PS,MACRF=GL, X
RECFM=FB,EXLST=EXITLIST
EXITLIST DC X'91',AL3(FERROR)
REQU
DCBD DSORG=PS
PARM DSECT
RC DC H'0'
SAVE DS 18F
EJECT
END &CSECT
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19243
Location: Inside the Matrix

PostPosted: Thu May 31, 2012 8:15 pm
Reply with quote

Hello,

Is there some reason you will not use the Code tag . . . ?

You did notice that instead of an 013-20 you now have an 013-34. . .
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2481
Location: Netherlands, Amstelveen

PostPosted: Thu May 31, 2012 10:30 pm
Reply with quote

Bill O'Boyle wrote:
Good find, Peter.... icon_smile.gif


Thanks Bill, i did write some DCB exits when i was still young and eager doing things to explore the paths of exits, control blocks (and glory of course).
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2481
Location: Netherlands, Amstelveen

PostPosted: Fri Jun 01, 2012 1:36 pm
Reply with quote

Try this :

Code:

FERROR EQU *
       MESG 'INVALID BLOCK SIZE FILE'
       L      R13,4(R13)           RESTORE CALLERS SAVE AREA
       RETURN (14,12),RC=0
Back to top
View user's profile Send private message
Ravi Kuchi

New User


Joined: 29 May 2012
Posts: 14
Location: INDIA

PostPosted: Fri Jun 01, 2012 1:48 pm
Reply with quote

Hi Peter,

I have tried but am not successful.

- Thanks
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2454
Location: Hampshire, UK

PostPosted: Fri Jun 01, 2012 3:54 pm
Reply with quote

Ravi Kuchi wrote:
I have tried but am not successful.

Totally useless reply unless you are not wanting further help.
Back to top
View user's profile Send private message
Ravi Kuchi

New User


Joined: 29 May 2012
Posts: 14
Location: INDIA

PostPosted: Fri Jun 01, 2012 4:09 pm
Reply with quote

Excuse me if I am not responding properly,as I already informed I do not know much of assembly langauage.

Here is what I think is happening, once the OPEN MACRO encounters the file error, the control is transferred to FERROR routine (please see the entire code pasted in previous pages). But still the control lies within the OPEN MACRO and though I want to EXIT from this it wouldn't.

So looking for a mechanism which could allow the program to exit from the control of the OPEN MACRO.

Once again please excuse me if I do not make any sense.
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2481
Location: Netherlands, Amstelveen

PostPosted: Fri Jun 01, 2012 5:45 pm
Reply with quote

PeterHolland wrote:
Try this :

Code:

FERROR EQU *
       MESG 'INVALID BLOCK SIZE FILE'
       L      R13,4(R13)           RESTORE CALLERS SAVE AREA
       RETURN (14,12),RC=0


Forget about previous comment. That will not work, wrong piece of code.
But once again read : DFSMS Using Datasets chapter 31. And read the following link :
publib.boulder.ibm.com/infocenter/zvm/v5r4/index.jsp?topic=/com.ibm.zvm.v54.dmsa5/hcsd2b00507.htm
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19243
Location: Inside the Matrix

PostPosted: Fri Jun 01, 2012 7:11 pm
Reply with quote

Hello,

Quote:
Excuse me if I am not responding properly,as I already informed I do not know much of assembly langauage.
Knowledge of assembler is NOT needed to post what error(s) happened.

Posting "it didn't work" is a complete waste of time for you as well as those who want to help.

When something does not work, you need to post what you tried (not all of the code, just the problem bit), what error(s) occurred, and any diagnostic info provided by the compile or execution. If someone wants something additional, they will ask for it in their reply.
Back to top
View user's profile Send private message
Ravi Kuchi

New User


Joined: 29 May 2012
Posts: 14
Location: INDIA

PostPosted: Tue Jun 05, 2012 4:43 pm
Reply with quote

Thanks to all of you for helping me out,

Special thanks to Peter for his inputs which saved a lot of time.

Thanks!
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> PL/I & Assembler Goto page Previous  1, 2

 


Similar Topics
Topic Forum Replies
No new posts IEW2315E 1369 Link error All Other Mainframe Topics 3
No new posts Help on IMS -API URL migrating from P... IMS DB/DC 1
No new posts MF professionals open positions Mainframe Jobs 0
No new posts SDUMPX macro fails to dump requested ... PL/I & Assembler 5
No new posts JES datasets IO Error ABENDS & Debugging 3
Search our Forums:

Back to Top