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 

Multiple file sort in the same sort step

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities
View previous topic :: View next topic  
Author Message
hariavinash
Beginner


Joined: 21 Jan 2005
Posts: 52
Topics: 7

PostPosted: Tue Nov 29, 2005 9:09 am    Post subject: Multiple file sort in the same sort step Reply with quote

hello people,

Is there a way to sort multiple files in the same sort step. ie

SORT
SORTIN FILEA
SORTOUT FILEB
SORTIN FILEC
SORTOUT FILED

SORT PARMS

any help is appreciated.
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


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

PostPosted: Tue Nov 29, 2005 9:41 am    Post subject: Reply with quote

hariavinash,

The following JCL will give you the desired results. If your shop has syncsort then change the pgm name to SYNCTOOL. IN1 will be sorted to OUT1, IN2 will be sorted to OUT2 and so on.. Note that even though this looks like a single step this actually is excueting 3 steps.

Code:

//STEP0100 EXEC PGM=ICETOOL
//*
//TOOLMSG   DD SYSOUT=*
//DFSMSG    DD SYSOUT=*
//IN1       DD DSN=XXXXX.INPUT1,
//             DISP=SHR
//*
//IN2       DD DSN=XXXXX.INPUT2,
//             DISP=SHR
//*
//IN3       DD DSN=XXXXX.INPUT3,
//             DISP=SHR
//*
//OUT1     DD DSN=XXXXXXX.OUTPUT1,
//            DISP=(NEW,CATLG,DELETE),
//            UNIT=SYSDA,
//            SPACE=(CYL,(X,Y),RLSE)
//*
//OUT2     DD DSN=XXXXXXX.OUTPUT2,
//            DISP=(NEW,CATLG,DELETE),
//            UNIT=SYSDA,
//            SPACE=(CYL,(X,Y),RLSE)
//*
//OUT3     DD DSN=XXXXXXX.OUTPUT3,
//            DISP=(NEW,CATLG,DELETE),
//            UNIT=SYSDA,
//            SPACE=(CYL,(X,Y),RLSE)
//*
//TOOLIN    DD *
  SORT FROM(IN1) TO(OUT1) USING(CTL1)
  SORT FROM(IN2) TO(OUT2) USING(CTL2)
  SORT FROM(IN3) TO(OUT3) USING(CTL3)
//CTL1CNTL DD *
  SORT FIELDS=(..)
//CTL2CNTL DD *
  SORT FIELDS=(..)
//CTL3CNTL DD *
  SORT FIELDS=(..)
//*



Hope this helps...

Cheers

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
hariavinash
Beginner


Joined: 21 Jan 2005
Posts: 52
Topics: 7

PostPosted: Tue Nov 29, 2005 10:20 am    Post subject: Reply with quote

Thank you very much. This works fine.
cheers
Back to top
View user's profile Send private message
Frank Yaeger
Sort Forum Moderator
Sort Forum Moderator


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

PostPosted: Tue Nov 29, 2005 11:41 am    Post subject: Reply with quote

Quote:
even though this looks like a single step this actually is excueting 3 steps.


Actually it is a SINGLE STEP, but it performs three passes over the data.
_________________
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
Back to top
View user's profile Send private message Send e-mail Visit poster's website
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