View previous topic :: View next topic
|
Author |
Message |
ksathishkumar83
New User
Joined: 21 Nov 2006 Posts: 50 Location: India
|
|
|
|
Hi,
I need to execute step3 depending on the Return codes of previous two steps step1 and step2.
step3--should not execute when both step1 and step2 return code is 4.
when any one of the step has a return code other than 4,step3
should run.
Please provide me the condition code needed for this. |
|
Back to top |
|
|
CICS Guy
Senior Member
Joined: 18 Jul 2007 Posts: 2146 Location: At my coffee table
|
|
Back to top |
|
|
ksathishkumar83
New User
Joined: 21 Nov 2006 Posts: 50 Location: India
|
|
|
|
Hi,
I have tried and able to get the solution.
i want to code the condition like below
// If step1.rc not equal to 4 OR Step2.rc not equal e
//step3 exec
//.....
// endif |
|
Back to top |
|
|
CICS Guy
Senior Member
Joined: 18 Jul 2007 Posts: 2146 Location: At my coffee table
|
|
Back to top |
|
|
Bill Dennis
Active Member
Joined: 17 Aug 2007 Posts: 562 Location: Iowa, USA
|
|
|
|
You first said BOTH steps must be CC=4 to run step3. Your sample code says OR.
Which do you want? |
|
Back to top |
|
|
Bill Dennis
Active Member
Joined: 17 Aug 2007 Posts: 562 Location: Iowa, USA
|
|
|
|
Bill Dennis wrote: |
You first said BOTH steps must be CC=4 to run step3. Your sample code says OR.
Which do you want? |
Oops. I was backwards. You said "BOTH steps must be CC=4 to skip step3". Is it OR or AND? |
|
Back to top |
|
|
ksathishkumar83
New User
Joined: 21 Nov 2006 Posts: 50 Location: India
|
|
|
|
I said step3 should not run only when both steps step1 and step2's return codes are 4.
my sample code is
// If step1.rc not equal to 4 OR Step2.rc not equal 4
//step3 exec
//.....
// endif
when step1 rc=4 and step2 rc=0
If step1.rc not equal to 4 OR Step2.rc not equal 4
step 3 will exexute
when step1 and step2 both rc=4
If step1.rc not equal to 4 OR Step2.rc not equal 4
both these condition will be false,so step3 will not execute |
|
Back to top |
|
|
Bill Dennis
Active Member
Joined: 17 Aug 2007 Posts: 562 Location: Iowa, USA
|
|
|
|
You have almost coded the solution yourself.
Code: |
// IF (STEP1.RC ^= 4 OR STEP2.RC ^= 4) THEN
//STEP03 EXEC PGM=xxxxx
// ENDIF |
|
|
Back to top |
|
|
Anuj Dhawan
Superior Member
Joined: 22 Apr 2006 Posts: 6248 Location: Mumbai, India
|
|
|
|
Bill Dennis wrote: |
You have almost coded the solution yourself. |
With the exp. level & exposure you own You guys are supportive enough. Thanks for being here... |
|
Back to top |
|
|
ksathishkumar83
New User
Joined: 21 Nov 2006 Posts: 50 Location: India
|
|
|
|
Hi,
when i tried the below code,i am getting Error that ^-should not be used with IF.
// IF (STEP1.RC ^= 4 OR STEP2.RC ^= 4) THEN
//STEP03 EXEC PGM=xxxxx
// ENDIF |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19243 Location: Inside the Matrix
|
|
|
|
Hello,
I believe the jcl checker may be looking for x'5F' rather than x'B0'. . .
If i remember, you could use NOT instead of the not symbol. |
|
Back to top |
|
|
Terry Heinze
JCL Moderator
Joined: 14 Jul 2008 Posts: 1248 Location: Richfield, MN, USA
|
|
|
|
Try NE instead of ^=. |
|
Back to top |
|
|
Terry Heinze
JCL Moderator
Joined: 14 Jul 2008 Posts: 1248 Location: Richfield, MN, USA
|
|
|
|
... or look it up in the JCL manual. |
|
Back to top |
|
|
|