Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Forum Index
 
Register
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
DSNTEP2 - setting exception

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2
View previous topic :: :: View next topic  
Author Message
jzhardy

New User


Joined: 31 Oct 2006
Posts: 76
Location: brisbane

PostPosted: Thu May 28, 2020 4:51 pm    Post subject: DSNTEP2 - setting exception
Reply with quote

in SQL I can force an exception (ie SQL state), but the net result is that the Job Step gets an RC 8.

Is there any way I can elevate the RC to a higher value ? Note that the step could fail for another condition - eg, insufficient user privileges - and for these I would always want to see RC 8. But I need to be able to identify a special condition based on RC.

I'll provide more details tomorrow as I'm writing this away from work.
Back to top
View user's profile Send private message

prino

Senior Member


Joined: 07 Feb 2009
Posts: 1206
Location: Vilnius, Lithuania

PostPosted: Thu May 28, 2020 10:08 pm    Post subject:
Reply with quote

In PL/I

"if my_special_condition_is_met then call pliretv(42);"

And COBOL has a similar way to set return codes
Back to top
View user's profile Send private message
enrico-sorichetti

Senior Member


Joined: 14 Mar 2007
Posts: 10690
Location: italy

PostPosted: Thu May 28, 2020 10:50 pm    Post subject: Reply to: DSNTEP2 - setting exception
Reply with quote

the source for dsntep2 is available and can be modified,
You just need a pl/I compiler

the idug once upon a time used to have CSNTEP2 the equivalent of dsntep2 but written in cobol

it still there, not the latest thing but You might get a few ideas out of it

https://www.idug.org/page/codeplace-listing
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2 All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Execute DSNTEP2 in REXX which is call... sushanth bobby CLIST & REXX 4 Wed Mar 04, 2020 3:27 pm
No new posts Setting up a name counter in the coup... Mike.Fulton CICS 2 Tue Dec 25, 2018 1:34 am
This topic is locked: you cannot edit posts or make replies. S0C4-X'11' issue - page translation e... ashek15 JCL & VSAM 10 Wed Aug 15, 2018 4:23 am
No new posts Conditional setting of return-code af... sanvan COBOL Programming 9 Wed Jan 31, 2018 11:05 pm
No new posts Setting Font Type for XMIT satish.ms10 All Other Mainframe Topics 3 Fri Sep 15, 2017 10:01 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us