Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Checking for Return Codes of prevoious Steps

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
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    Post subject: Checking for Return Codes of prevoious Steps
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: 1187
Location: Bangalore,India

PostPosted: Mon Jan 29, 2007 4:25 pm    Post subject:
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    Post subject:
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    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts EXIT or RETURN cvnlynn CLIST & REXX 16 Wed Jul 19, 2017 2:50 am
No new posts NDM syntax checking without actually ... GAPX1 All Other Mainframe Topics 0 Wed Jun 07, 2017 2:36 am
No new posts QUESTION: RETURN CHANNEL pahiker CA Products 21 Thu Apr 20, 2017 12:31 am
No new posts JCL to Set Return code based on DB2 S... vinu78 DB2 17 Mon Mar 13, 2017 9:47 pm
No new posts Checking Current date vickey_dw DFSORT/ICETOOL 1 Wed Feb 08, 2017 11:14 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us