Adding SEQNUM
Posted: Mon Feb 15, 2010 8:48 pm
Hi,
Using your excellent forum I have managed to successfully use the JOINKEYS function to give me unmatched records from 2 variable length files.
However the original files have the following format:
00 Header record
D: Lots of delimited data
99 Footer Record
So when I run the JOINKEYS code it also sorts the data (by record length) and gives me:
99 Footer Record
00 Header Record
D: my unmtached data.
The rest of my processing requires the records to be in the original order.
I used SORT FIELDS=COPY. I note from one of your other replies that it's possible to add a SEQNUM so I could sort it again afterwards.
I've been trying all morning and getting lots of errors such as WER244A OUTREC - SHORT RECORD.
We generally use files that are VB 27994 - this is the latest in a long line of attempts:
//SAVL01S JOB 1,NTC,MSGLEVEL=(1,1),MSGCLASS=X,TIME=1440
//*MAIN CLASS=LONG
//SORT1 EXEC PGM=SYNCSORT,REGION=150M,COND=(0,NE)
//SORTIN DD DSN=SBCL.£SAVLQ0.ML2RAW.D2100206.NTSS.F002.N000,
// DISP=SHR
//SORTOUT DD DSN=SAVL01.NTCTEST.SORTDUPA.OUT,
// DCB=(RECFM=VB,LRECL=27994,DSORG=PS),
// UNIT=SYSDA,VOL=(,,,40),MGMTCLAS=ML2BACK1,
// SPACE=(TRK,(30000,4000),RLSE),
// DISP=(NEW,CATLG)
//SYSOUT DD SYSOUT=*
//SYSIN DD *
SORT FIELDS=COPY,STOPAFT=10
OUTREC FIELDS=(1,27986,SEQNUM,8,ZD)
//
Any help appreciated.
Thanks,
Mike.
Using your excellent forum I have managed to successfully use the JOINKEYS function to give me unmatched records from 2 variable length files.
However the original files have the following format:
00 Header record
D: Lots of delimited data
99 Footer Record
So when I run the JOINKEYS code it also sorts the data (by record length) and gives me:
99 Footer Record
00 Header Record
D: my unmtached data.
The rest of my processing requires the records to be in the original order.
I used SORT FIELDS=COPY. I note from one of your other replies that it's possible to add a SEQNUM so I could sort it again afterwards.
I've been trying all morning and getting lots of errors such as WER244A OUTREC - SHORT RECORD.
We generally use files that are VB 27994 - this is the latest in a long line of attempts:
//SAVL01S JOB 1,NTC,MSGLEVEL=(1,1),MSGCLASS=X,TIME=1440
//*MAIN CLASS=LONG
//SORT1 EXEC PGM=SYNCSORT,REGION=150M,COND=(0,NE)
//SORTIN DD DSN=SBCL.£SAVLQ0.ML2RAW.D2100206.NTSS.F002.N000,
// DISP=SHR
//SORTOUT DD DSN=SAVL01.NTCTEST.SORTDUPA.OUT,
// DCB=(RECFM=VB,LRECL=27994,DSORG=PS),
// UNIT=SYSDA,VOL=(,,,40),MGMTCLAS=ML2BACK1,
// SPACE=(TRK,(30000,4000),RLSE),
// DISP=(NEW,CATLG)
//SYSOUT DD SYSOUT=*
//SYSIN DD *
SORT FIELDS=COPY,STOPAFT=10
OUTREC FIELDS=(1,27986,SEQNUM,8,ZD)
//
Any help appreciated.
Thanks,
Mike.