Matches keyword write the



Support for NetApp SyncSort for z/OS, Visual SyncSort, SYNCINIT, SYNCLIST and SYNCTOOL

Re: Matches keyword write the

Postby deva_048 » Fri Oct 24, 2014 9:57 am

I have used the below code and got the expected output mentioned in the above post.. But only one clarification when i tried to generate sequence number in jcl control card the sequence number is generated like below: (Looks like the sequence number generated from bottom to top) Can any one tell me why it is generating from bottom to top) ?
AAAA001|0003
AAAA001|0002
AAAA001|0001

 SORT FIELDS=(1,7,CH,A,81,4,ZD,D)                                     
 INREC IFTHEN=(WHEN=INIT,OVERLAY=(81:SEQNUM,4,ZD,RESTART=(1,7))),     
       IFTHEN=(WHEN=GROUP,BEGIN=(81,4,ZD,EQ,1),PUSH=(85:40,5))       
 OUTREC OVERLAY=(81:SEQNUM,4,ZD,RESTART=(1,7),40:85,5)               
 OUTFIL INCLUDE=(81,4,ZD,EQ,1),BUILD=(1,80)                           
/*
deva_048
 
Posts: 72
Joined: Thu Feb 02, 2012 9:28 pm
Has thanked: 1 time
Been thanked: 0 time

Re: Matches keyword write the

Postby BillyBoyo » Fri Oct 24, 2014 12:00 pm

You''ve generated the sequence number in INREC, which runs before the SORT. So, unless the data is already in the same order as the SORT key, you sequence numbers will not be in order.

You can't tell SORT what order to do things in. You can code SORT before INREC but INREC will always run first.

You can add your sequence number instead in OUTREC or in OUTFIL.
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 265 times

Re: Matches keyword write the

Postby NicC » Sun Oct 26, 2014 4:11 am

i tried to generate sequence number in jcl control card

No you didn't. No such thing as a 'jcl control card'. It was a SORT control card which is why you posted the sort control cards.
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 3025
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisies (almost)
Has thanked: 4 times
Been thanked: 136 times

Previous

Return to Syncsort/Synctool

 


  • Related topics
    Replies
    Views
    Last post