MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Keeping dropped duplicate records

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities
View previous topic :: View next topic  
Author Message
Frank Yaeger
Sort Forum Moderator
Sort Forum Moderator


Joined: 02 Dec 2002
Posts: 1618
Topics: 31
Location: San Jose

PostPosted: Tue Dec 03, 2002 7:35 pm    Post subject: Keeping dropped duplicate records Reply with quote

For more information on how you can use DFSORT's ICETOOL to split an input file with duplicate records into two output data sets in various ways, see the "Split a file to n output files dynamically" and "Five ways to split a data set" Smart DFSORT Tricks at:

http://www.ibm.com/servers/storage/support/software/sort/mvs/tricks/
_________________
Frank Yaeger - DFSORT Development Team (IBM)
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
DFSORT is on the Web at:
www.ibm.com/storage/dfsort


Last edited by Frank Yaeger on Thu Sep 14, 2006 4:46 pm; edited 1 time in total
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Subzero
Beginner


Joined: 02 Dec 2002
Posts: 19
Topics: 7
Location: Chennai, India

PostPosted: Wed Dec 04, 2002 2:58 am    Post subject: Reply with quote

Our installations supports syncsort only. And I need to sort a file into two seperate output files based on two different sort fields. How can I do this? Rolling Eyes

Subzero
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12370
Topics: 75
Location: San Jose

PostPosted: Wed Dec 04, 2002 4:07 am    Post subject: Reply with quote

Subzero,

Please post a sample of input and the desired output

Thanks

kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Subzero
Beginner


Joined: 02 Dec 2002
Posts: 19
Topics: 7
Location: Chennai, India

PostPosted: Wed Dec 04, 2002 8:30 am    Post subject: Reply with quote

Kolusu,
One of the example is that the input file contains records with name and age columns. The first output file must have all records sorted by name and the second output file must have all records sorted by age. I need this to be done using syncsort. Please help.

Subzero Sad
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12370
Topics: 75
Location: San Jose

PostPosted: Wed Dec 04, 2002 8:56 am    Post subject: Reply with quote

Subzero,
The following Jcl will give you the desired results.

Code:

//STEP0100 EXEC  PGM=SYNCTOOL           
//TOOLMSG  DD SYSOUT=*                 
//DFSMSG   DD SYSOUT=*                 
//IN       DD DSN=YOUR INPUT FILE,
//            DISP=SHR                       
//OUT1     DD DSN=YOUR OUTPUT SORTED FILE ON NAME,         
//            DISP=(NEW,CATLG,DELETE), 
//            UNIT=SYSDA,               
//            SPACE=(CYL,(X,Y),RLSE)   
//OUT2     DD DSN=YOUR OUTPUT SORTED FILE ON AGE,         
//            DISP=(NEW,CATLG,DELETE), 
//            UNIT=SYSDA,               
//            SPACE=(CYL,(X,Y),RLSE)   
//TOOLIN   DD    *             
  SORT FROM(IN) TO(OUT1) USING(CTL1)
  SORT FROM(IN) TO(OUT2) USING(CTL2)     
//CTL1CNTL DD    *             
  SORT FIELDS=(1,10,CH,A)   $ SORT FIELDS FOR NAME
//CTL2CNTL DD    *             
  SORT FIELDS=(11,3,ZD,A)   $ SORT FIELDS FOR AGE
/*
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Subzero
Beginner


Joined: 02 Dec 2002
Posts: 19
Topics: 7
Location: Chennai, India

PostPosted: Wed Dec 04, 2002 9:04 am    Post subject: Reply with quote

Laughing Thank you very much kolusu.. Laughing

Subzero
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group