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

Checking for Return Codes of prevoious Steps


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
ksathishkumar83

New User


Joined: 21 Nov 2006
Posts: 50
Location: India

PostPosted: Mon Jan 29, 2007 4:07 pm
Reply with quote

i have a JCl

//step 10
//step 20
//step 30
//step 40
// step 50

In step 50 i need to check the Return code of Step 10 and 20.how can it be done?
Back to top
View user's profile Send private message
guptae

Moderator


Joined: 14 Oct 2005
Posts: 1208
Location: Bangalore,India

PostPosted: Mon Jan 29, 2007 4:25 pm
Reply with quote

Hi there,

What do u want to do after checking return code of STEP10 & STEP20 ?
If u want to execute step50 depending on returncode of 10 & 20 then below might be helpful.

Code:
COND=(m,operator,stepname)


m return code to be used in comparison
0 step ran successfully
4 warning
8 an error exists (probable ABEND)
12 a serious error
16 a severe error
operator type of comparison to make
GT greater than
GE greater than or equal to
LT less than
LE less than or equal to
EQ equal to
NE not equal to
stepname name of the step whose return code is to
be used in the comparison (if stepname is not
used, the comparison is made to all preceding
return codes from all the preceding steps).
Back to top
View user's profile Send private message
prav_06
Warnings : 1

Active User


Joined: 13 Dec 2005
Posts: 154
Location: The Netherlands

PostPosted: Mon Jan 29, 2007 5:16 pm
Reply with quote

Hi Satish,
Instead of playing with the COND parameter u can also use the foll. coding

Before step50 code

Code:
//Check1 IF STEP10.RC [EQ/LT/NE/GT/GE] <Cond-code> Then
//Chech2 IF STEP20.RC [EQ/LT/NE/GT/GE] <Cond-code> Then
//Step50 EXEC
//dd
//dd
//dd
//Check1 endif
//Check2 endif


Cheer's,

Thamilzan.
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 -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts Return codes-Normal & Abnormal te... JCL & VSAM 7
No new posts CA7 deleting files in steps after job... CA Products 4
No new posts VSAM return code 23 - for a Random read COBOL Programming 4
No new posts AI writing DFSORT, REXX codes.. All Other Mainframe Topics 3
No new posts REXX - Dataset checking in a do forev... CLIST & REXX 6
Search our Forums:

Back to Top