View previous topic :: View next topic
|
Author |
Message |
gekalpana
New User
Joined: 11 Apr 2007 Posts: 12 Location: Chennai
|
|
|
|
HI
Please Let me know USING SORT how to sort records between header and trailer . I have searched for posts . But all are using either ICEMAN or ICETOOL ........ Pls let me know how that can be done using EXEC PGM=SORT ??
Thanks !! |
|
Back to top |
|
|
murmohk1
Senior Member
Joined: 29 Jun 2006 Posts: 1436 Location: Bangalore,India
|
|
Back to top |
|
|
gekalpana
New User
Joined: 11 Apr 2007 Posts: 12 Location: Chennai
|
|
|
|
Thanks .. But that uses ICEMAN ... I want SORT to be used |
|
Back to top |
|
|
William Thompson
Global Moderator
Joined: 18 Nov 2006 Posts: 3156 Location: Tucson AZ
|
|
|
|
sort/iceman, all the same product....
If you have IBM's DFSORT, you have "ICEMAN"..... |
|
Back to top |
|
|
gekalpana
New User
Joined: 11 Apr 2007 Posts: 12 Location: Chennai
|
|
|
|
We do have SYNCSORT only |
|
Back to top |
|
|
William Thompson
Global Moderator
Joined: 18 Nov 2006 Posts: 3156 Location: Tucson AZ
|
|
|
|
Well, that "might" change things...
What release of Syncsort? |
|
Back to top |
|
|
gekalpana
New User
Joined: 11 Apr 2007 Posts: 12 Location: Chennai
|
|
|
|
V1R2 |
|
Back to top |
|
|
William Thompson
Global Moderator
Joined: 18 Nov 2006 Posts: 3156 Location: Tucson AZ
|
|
|
|
You should be able to use the example a a guide with Syncsort.
Check the "Addendum. BUILD, IFTHEN, IFOUTLEN, and OVERLAY Parameters". |
|
Back to top |
|
|
murmohk1
Senior Member
Joined: 29 Jun 2006 Posts: 1436 Location: Bangalore,India
|
|
Back to top |
|
|
Anuj Dhawan
Superior Member
Joined: 22 Apr 2006 Posts: 6250 Location: Mumbai, India
|
|
|
|
Hi,
Link & indication provided by Murali should have worked for you. Try below JCL, it should work for you (SyncSort site)
Input file is of LRECL=80 & I assume Header & Trailer are determined by 'H' & 'T' as their first letter.
Code: |
//STEP050 EXEC PGM=SORT,REGION=4096K
//*
//SORTIN DD DSN=HLQ.HDR.TLR.FILE,
// DISP=SHR
//SORTOUT DD DSN=HLQ.HDR.TLR.FILE.OUT,
// DISP=(NEW,CATLG,CATLG),
// DSORG=PS,
// RECFM=FB,
// LRECL=80,
// DATACLAS=LARGE,
// UNIT=SYSDA
//SORTWK01 DD UNIT=SYSDA,SPACE=(CYL,(20,5))
//SYSIN DD *
INREC IFTHEN=(WHEN=INIT,OVERLAY=(81:C'1')),
IFTHEN=(WHEN=(1,1,CH,EQ,C'H'),OVERLAY=(81:C'0')),
IFTHEN=(WHEN=(1,1,CH,EQ,C'T'),OVERLAY=(81:C'9'))
SORT FIELDS=(81,1,CH,A,1,5,CH,A)
OUTREC FIELDS=(1,80)
/* |
In above JCL, input HLQ.HDR.TLR.FILE is:
& output HLQ.HDR.TLR.FILE.OUT is:
Hope this helps. |
|
Back to top |
|
|
Frank Yaeger
DFSORT Developer
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
|
|
|
|
Quote: |
But all are using either ICEMAN ........ Pls let me know how that can be done using EXEC PGM=SORT ?? |
PGM=ICEMAN and PGM=SORT are equivalent. They both invoke the sort product at your site (DFSORT, Syncsort, CA-Sort). Of course, the sort products are different, but PGM=ICEMAN vs PGM=SORT has nothing to do with that. |
|
Back to top |
|
|
|