Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Set Return Code based on the value in the input file

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
Nites300

New User


Joined: 22 Jan 2008
Posts: 4
Location: India

PostPosted: Mon Nov 17, 2008 11:17 am    Post subject: Set Return Code based on the value in the input file
Reply with quote

Hi,

I have a situation where i want to set the return based on the value in the input file.

Say suppose in INPUT file value is 'Y' i want to set it to Zero if it's 'N' set to '4'
Back to top
View user's profile Send private message

dick scherrer

Site Director


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

PostPosted: Mon Nov 17, 2008 11:19 am    Post subject:
Reply with quote

Hello,

Do you have File-Aid installed?

Which sort do you have installed?

Are there other utilities your shop prefers used?
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Mon Nov 17, 2008 11:27 am    Post subject:
Reply with quote

Hi,

are they the only 2 possible values in the file, and what col are they in ?


Gerry
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2352
Location: @my desk

PostPosted: Mon Nov 17, 2008 11:33 am    Post subject:
Reply with quote

Hi,

Is there only a single record in your input file?
Back to top
View user's profile Send private message
Nites300

New User


Joined: 22 Jan 2008
Posts: 4
Location: India

PostPosted: Mon Nov 17, 2008 1:15 pm    Post subject:
Reply with quote

yes there will be single record in file on that basis i want to set the return code
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2352
Location: @my desk

PostPosted: Mon Nov 17, 2008 1:40 pm    Post subject:
Reply with quote

Quote:
are they the only 2 possible values in the file
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Mon Nov 17, 2008 1:44 pm    Post subject:
Reply with quote

Hi,

if you have DFSORT, you can try this, if it equals Y it will return a zero else it will return a 4

Code:
//STEP1    EXEC PGM=SORT                           
//SYSOUT   DD SYSOUT=*                             
//SORTIN   DD *                                     
Y                                                 
/*                                                 
//SORTOUT  DD DUMMY                                 
//SYSIN    DD *                                     
   OPTION COPY,NULLOUT=RC4                         
   INCLUDE COND=(1,1,CH,EQ,C'Y')                   



Gerry
Back to top
View user's profile Send private message
Nites300

New User


Joined: 22 Jan 2008
Posts: 4
Location: India

PostPosted: Mon Nov 17, 2008 2:11 pm    Post subject:
Reply with quote

thanks a lot.this worked
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 IDCAMS RENAMING VSAM FILE ALONG WITH ... upendrasri JCL & VSAM 11 Tue Apr 17, 2018 10:42 pm
No new posts VSAM file NOT Found error while proce... SumaReva CICS 5 Wed Apr 11, 2018 9:54 pm
No new posts Getting GG return code abdulrafi IMS DB/DC 2 Tue Apr 10, 2018 12:31 pm
No new posts converting a mainframe file with ASA ... Lynne Schuler All Other Mainframe Topics 5 Wed Apr 04, 2018 9:44 am
No new posts VSAM File free space sancraig16 JCL & VSAM 13 Fri Mar 30, 2018 1:02 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us