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
 

 

Can we have some Return code from SYNCSORT statements

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

New User


Joined: 25 Jan 2008
Posts: 18
Location: India

PostPosted: Fri Jan 25, 2008 4:19 pm    Post subject: Can we have some Return code from SYNCSORT statements
Reply with quote

I am using SYNCSORT to find out the presence of certain strings in a PS file. Can we have any type of return code from the SORT method only to know the presence of the string searched.

What I am doing now is coying the desired records in some other file and then checking weather it has any records or not using IDCAMS.
Back to top
View user's profile Send private message

acevedo

Active User


Joined: 11 May 2005
Posts: 344
Location: Spain

PostPosted: Fri Jan 25, 2008 4:29 pm    Post subject:
Reply with quote

search for the NULLOFL parameter.
Back to top
View user's profile Send private message
krisprems

Active Member


Joined: 27 Nov 2006
Posts: 649
Location: India

PostPosted: Sat Jan 26, 2008 10:07 am    Post subject:
Reply with quote

This SORT JCL returns 4 if the string "NAME" was not found in inout file at the position 1,4.

Code:
//*******************************************************
//STEP1    EXEC PGM=SORT                                 
//SYSOUT   DD SYSOUT=*                                   
//SORTIN   DD *                                         
NAME
ADDR
LKMN
/*                                                       
//SORTOUT  DD DUMMY                                     
//SYSIN    DD *   
   OPTION COPY,NULLOUT=RC4           
   INCLUDE COND=(1,4,CH,EQ,C'NAME')                                       
 /*     
Back to top
View user's profile Send private message
vishal.iitr2003
Currently Banned

New User


Joined: 25 Jan 2008
Posts: 18
Location: India

PostPosted: Thu Jan 31, 2008 1:39 pm    Post subject:
Reply with quote

thank u
kRISPREMs
Back to top
View user's profile Send private message
acevedo

Active User


Joined: 11 May 2005
Posts: 344
Location: Spain

PostPosted: Thu Jan 31, 2008 3:06 pm    Post subject:
Reply with quote

with a slight meaning...you can code it in the PARM, for example:

Code:

//*----------------------------------------------------
//ICEMAN   EXEC PGM=ICEMAN,PARM='NULLOUT=RC4'         
//SYSOUT    DD SYSOUT=*                               
//SORTIN    DD *                                       
AAAAAAAAAAAAAAAAAA                                     
BBBBBBBBBBBBBBBBBBB                                   
CCCCCCCCCCCCCCCCCCCCCC                                 
CCESTACCCCCCCCCCCCCCCC                                 
DDDDDDDDDDDDDDDDDDDDDDDD                               
/*                                                     
//SORTOUT   DD SYSOUT=*                               
//SYSIN     DD *                                       
  OPTION  COPY                                         
  INCLUDE COND=(1,80,SS,EQ,C'XYZ')                     
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 Job failing with USER = 4093 REASON C... Pradeepa S ABENDS & Debugging 1 Wed May 17, 2017 3:35 pm
No new posts COBOL Code Parsers and Lineage Establ... balimanja COBOL Programming 2 Tue May 02, 2017 3:30 am
No new posts Cobol upgrade - source code missing f... gthmrj IBM Tools 1 Wed Apr 26, 2017 6:04 pm
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


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