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

Can any1 explain me about OUTREC in syncsort utility?


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

New User


Joined: 03 Aug 2006
Posts: 42
Location: Chennai

PostPosted: Sat Feb 10, 2007 3:41 pm
Reply with quote

Hi,

Can any1 please explain me about the OUTREC and CHANGE statement in SYNC SORT utility and how its working?

Thank you,
Mk icon_smile.gif
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Sat Feb 10, 2007 4:46 pm
Reply with quote

The CHANGE subparameter changes an input field to a replacement value in the reformatted output record if the input field equals a search constant. The input field remains unchanged on the input side.
Back to top
View user's profile Send private message
guptae

Moderator


Joined: 14 Oct 2005
Posts: 1208
Location: Bangalore,India

PostPosted: Tue Feb 13, 2007 10:02 am
Reply with quote

Hi MK,

Please find an example for this

Code:
//STEP001  EXEC PGM=SORT                                             
//SORTLIB  DD DSN=SYS1.SORTLIB,DISP=SHR                             
//SORTWK01 DD SPACE=(CYL,(100)),UNIT=DISK                           
//SYSIN    DD  *                                                     
   OPTION COPY                                                       
   OUTFIL OUTREC=(1:1,4,                                             
   5:5,3,CHANGE=(3,C'123',C'A01'),NOMATCH=(5,3),                     
   8:8,73)                                                           
/*                                                                   
//SORTIN   DD  DSN=TBH2.SCHNOMTC.SORTIN.DATA,DISP=SHR               
//SORTOUT  DD  DSN=TBH2.SCHNOMTC.SORTOUT.DATA,                       
//             UNIT=DISK,SPACE=(TRK,(1,1),RLSE),DISP=(,CATLG,DELETE),
//             DCB=(LRECL=80,BLKSIZE=800,RECFM=FB)                   
//SYSOUT   DD  SYSOUT=*                                             
//SYSOUT   DD SYSOUT=*                                               
//STATOUT DD SYSOUT=*                                               
//SYSUDUMP DD SYSOUT=*     


Here the output file contain first 4 byte of i/p file then from 5 th to 7 byte it will contain A01 if i/p file contain 123 otherwise the value of i/p file from 5th to 7 byte then from 8th to 80 byte again it will be containg value of 8th to 80 th byte of i/p file.

Hope it will helpful
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 Compare only first records of the fil... SYNCSORT 7
No new posts REASON 00D70014 in load utility DB2 6
No new posts DB2 Statistics - Using EXPLAIN and qu... DB2 1
No new posts ISRSUPC search utility - using high l... TSO/ISPF 2
No new posts Count Records with a crietaria in a f... DFSORT/ICETOOL 5
Search our Forums:

Back to Top