View previous topic :: View next topic |
Author |
Message |
Beswar Beginner
Joined: 04 Feb 2003 Posts: 33 Topics: 15
|
Posted: Tue Mar 29, 2005 9:00 am Post subject: Regarding CONd Codes |
|
|
Hi
I have a problem using the condintion codes in the jcl. in my job I am using 4 procs. if the second step of first proc gives more than zero return code, I want to execute the one step in the JCL. but that step would not in the proc and it would be in the JOB. Could anybody how to do this
Thanks
Eswar |
|
Back to top |
|
 |
kolusu Site Admin

Joined: 26 Nov 2002 Posts: 12378 Topics: 75 Location: San Jose
|
Posted: Tue Mar 29, 2005 1:06 pm Post subject: |
|
|
beswar,
If I understand your question correctly , you want to validate the return code of a step in a catalogued procedure in the JCL.
For example you have proc1 with 2 steps in it .
Code: |
//PROC1 PROC
//P1STEP1 DD EXEC PGM=..
...
//P1STEP2 DD EXEC PGM=..
|
Now your JCL looks as below
Code: |
//JSTEP1 EXEC PROC1
//JSTEP2 EXEC PGM=..
|
Now you want to validate the return code of p1step2 for Jstep2? You don't want to run JSTEP2 if p1step2 issues a return code of zero. You can do that simply by coding as shown below.
Code: |
//JSTEP2 EXEC PGM=SORT,COND=(0,EQ,JSTEP1.P1STEP2)
|
Hope this helps...
Cheers
Kolusu _________________ Kolusu
www.linkedin.com/in/kolusu |
|
Back to top |
|
 |
|
|