Joined: 26 Nov 2002 Posts: 12378 Topics: 75 Location: San Jose
Posted: Mon Aug 15, 2005 8:18 am Post subject:
Vijay,
Try this untested JCL. I assumed that your input is of FB type with an lrecl of 80 bytes. I also assumed that the indicator(a,b,c,d) is in pos 1.
Code:
//STEP0100 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD *
----+----1----+----2----+----3----+----4----+
A 22222
A 11111
A 44444
B 33333
B 22222
B 11111
C 22222
C 11111
C 44444
D 33333
D 22222
D 11111
//SORTOUT DD SYSOUT=*
//SYSIN DD *
INREC IFTHEN=(WHEN=(1,1,CH,EQ,C'A'),
OVERLAY=(81:10,5)),
IFTHEN=(WHEN=(1,1,CH,EQ,C'B'),
OVERLAY=(81:15,5)),
IFTHEN=(WHEN=(1,1,CH,EQ,C'C'),
OVERLAY=(81:20,5)),
IFTHEN=(WHEN=(1,1,CH,EQ,C'D'),
OVERLAY=(81:25,5)),
IFTHEN=(WHEN=NONE,
OVERLAY=(81:C'99999'))
Joined: 26 Nov 2002 Posts: 12378 Topics: 75 Location: San Jose
Posted: Mon Aug 15, 2005 8:51 am Post subject:
Quote:
Kolusu,
Are you sure this works with syncsort.I need to use SYncsort.
vijay,
Go thru your first post once again and see you have ever mentioned that you need to use Syncsort.
How do you expect me to guess what is on your mind? You haven't posted any details like LRECL,RECFM and position of the indicator. I just posted the example based on my assumptions.
Try the second example posted. It works for syncsort.
Next time you seek help please try to provide all the details and which would avoid the guesswork for the people who are trying to help.
Joined: 02 Dec 2002 Posts: 1618 Topics: 31 Location: San Jose
Posted: Mon Aug 15, 2005 10:05 am Post subject:
Quote:
Try this untested JCL.
Kolusu,
Your job works fine with DFSORT.
Quote:
Are you sure this works with syncsort.I need to use SYncsort.
Vijay,
You'll need z/OS DFSORT V1R5 PTF UQ95214 or DFSORT R14 PTF UQ95213 (Dec, 2004) in order to use DFSORT's IFTHEN and OVERLAY functions. Only DFSORT has these functions, so since you don't have DFSORT, you won't be able to use them. For complete details on all of the new DFSORT and ICETOOL functions available with the Dec, 2004 PTF, see:
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