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
 
Can any1 explain me about OUTREC in syncsort utility?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
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    Post subject: Can any1 explain me about OUTREC in syncsort utility?
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: 3158
Location: Tucson AZ

PostPosted: Sat Feb 10, 2007 4:46 pm    Post subject:
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: 1187
Location: Bangalore,India

PostPosted: Tue Feb 13, 2007 10:02 am    Post subject:
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    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 Split 1 file into 10 output Files - S... Prasanth Kumar SYNCSORT 5 Sat Sep 16, 2017 12:02 am
No new posts WER268A OUTREC STATEMENT : SYNTAX E... frozenblood87 SYNCSORT 12 Sat Aug 26, 2017 9:45 pm
No new posts How to Use DebugTool CodeCoverage Uti... neo4u IBM Tools 0 Thu Jun 22, 2017 6:38 pm
No new posts Search utility(3.14) using JCl and Cobol RKS3 COBOL Programming 12 Sat Jun 10, 2017 10:24 pm
No new posts DB2 - TERMINATE utility vasanthz DB2 5 Mon May 15, 2017 11:49 pm

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