How to copy only one record after sorting to SORTOUT.
Posted: Wed Jan 12, 2011 2:10 pm
Hi All,
I have a sort card as below.
INCLUDE COND=(1,13,CH,EQ,C'abc-xyz-data')
SORT FIELDS=(15,4,CH,D,19,2,CH,D,21,2,CH,D,24,6,CH,D)
SORT FIELDS=COPY
It will pickup the rows which contains charector 'abc-xyz-data' in 1 to 13th position and then it will sort the as per the above condition and finally it will write all records to SORTOUT file.
After sorting i want only first record to placed in the SORTOUT. How it can be achived.
Please suggest.
Thanks
Husen
I have a sort card as below.
INCLUDE COND=(1,13,CH,EQ,C'abc-xyz-data')
SORT FIELDS=(15,4,CH,D,19,2,CH,D,21,2,CH,D,24,6,CH,D)
SORT FIELDS=COPY
It will pickup the rows which contains charector 'abc-xyz-data' in 1 to 13th position and then it will sort the as per the above condition and finally it will write all records to SORTOUT file.
After sorting i want only first record to placed in the SORTOUT. How it can be achived.
Please suggest.
Thanks
Husen