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

What COND statement will be used ?


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

New User


Joined: 28 May 2007
Posts: 6
Location: Hyderabad

PostPosted: Thu Dec 16, 2010 8:04 pm
Reply with quote

Hi all,

I have 3 steps in a job . Now i want that step 2 will always be bypassed. What will be the COND statement for that?


Please help me out.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu Dec 16, 2010 8:14 pm
Reply with quote

If you understand how the COND parameter works, then it should be easy to determine the correct code.

I suggest that you click the "IBM Manuals" button at the top of any page, and take a good read of the sections for COND and IF/THEN/ELSE/ENDIF

If you still have doubts, then post again
Back to top
View user's profile Send private message
Garry Carroll

Senior Member


Joined: 08 May 2006
Posts: 1193
Location: Dublin, Ireland

PostPosted: Thu Dec 16, 2010 9:10 pm
Reply with quote

Quote:
Now i want that step 2 will always be bypassed


Why not just remove step 2 ? If it's never to be executed it just adds to confusion.

Garry.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Thu Dec 16, 2010 10:07 pm
Reply with quote

Hello,

Quote:
I have 3 steps in a job . Now i want that step 2 will always be bypassed.
Why does someone believe this should even be considered?
Back to top
View user's profile Send private message
fredrick andrews

New User


Joined: 10 Jun 2010
Posts: 52
Location: chennai

PostPosted: Fri Dec 17, 2010 4:18 pm
Reply with quote

king.hyd wrote:
Hi all,

I have 3 steps in a job . Now i want that step 2 will always be bypassed. What will be the COND statement for that?


Please help me out.


As others said, you can remove that 2nd job step or comment that out.
Back to top
View user's profile Send private message
sandhyaimmadi

New User


Joined: 18 Aug 2008
Posts: 50
Location: Bangalore

PostPosted: Mon Dec 27, 2010 7:16 pm
Reply with quote

You can give (4095,GT)
Back to top
View user's profile Send private message
Jeffrey Ranney

New User


Joined: 23 Dec 2010
Posts: 20
Location: USA

PostPosted: Tue Dec 28, 2010 6:06 pm
Reply with quote

I always use the IF/THEN/ELSE construct which gives greater control.
Back to top
View user's profile Send private message
king.hyd

New User


Joined: 28 May 2007
Posts: 6
Location: Hyderabad

PostPosted: Fri Dec 31, 2010 12:32 pm
Reply with quote

I think (4095,GT) shuld be the correct answer. Thanks
Back to top
View user's profile Send private message
Garry Carroll

Senior Member


Joined: 08 May 2006
Posts: 1193
Location: Dublin, Ireland

PostPosted: Tue Jan 04, 2011 7:53 pm
Reply with quote

... and what if a step in the job gives return code 4096 or higher?

Garry.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8697
Location: Dubuque, Iowa, USA

PostPosted: Tue Jan 04, 2011 8:20 pm
Reply with quote

z/OS return codes will be in the range 0 to 4095, hence this in the JCL Language Reference manual:
Quote:
16.5.2 Subparameter Definition



code
Specifies a number that the system compares to the return codes from all previous steps in the job or from specific steps. code is a decimal number from 0 through 4095.
Note: Specifying a decimal number greater than 4095 could result in invalid return code testing or invalid return codes in messages.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Tue Jan 04, 2011 10:10 pm
Reply with quote

Hello,

I've encouraged many new people (students / trainees) to set the return-code to values in the 6 or 8 or 10k range just to see what happens. . .
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8697
Location: Dubuque, Iowa, USA

PostPosted: Tue Jan 04, 2011 10:20 pm
Reply with quote

FTP with the EXIT parameter sets the return code value to a five-digit number when the FTP fails, where the first two digits represent the FTP function that failed (27 for GET, 16 for PUT and so forth) followed by the three-digit reply code for the command. So FTP gets values like 27550 fairly regularly. Of course, the job doesn't see 27550 ...
Back to top
View user's profile Send private message
Dsingh29

Active User


Joined: 16 Dec 2008
Posts: 132
Location: IBM

PostPosted: Wed Jan 05, 2011 5:19 pm
Reply with quote

why not use (0,LT)...
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Wed Jan 05, 2011 8:52 pm
Reply with quote

Hello,

Possibly because zero is not less than zero. . .
Back to top
View user's profile Send private message
singhju

New User


Joined: 01 Dec 2010
Posts: 25
Location: Gurgaon

PostPosted: Thu Jan 06, 2011 10:17 am
Reply with quote

We can use (0,LE)
Back to top
View user's profile Send private message
Dsingh29

Active User


Joined: 16 Dec 2008
Posts: 132
Location: IBM

PostPosted: Fri Jan 07, 2011 11:52 am
Reply with quote

sorry, my bad...i meant (0,LE)...
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 INCLUDE OMIT COND for Multiple values... DFSORT/ICETOOL 5
No new posts JOIN STATEMENT PERFORMANCE. DFSORT/ICETOOL 12
No new posts Reference for COND parameter. JCL & VSAM 1
No new posts IEF142I and Cond. Code 12 All Other Mainframe Topics 3
No new posts Relate COBOL statements to EGL statement All Other Mainframe Topics 0
Search our Forums:

Back to Top