z/OS DFSORT Application Programming Guide
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Example 2

z/OS DFSORT Application Programming Guide
SC23-6878-00

RESIZE FROM(OLD) TO(NEW) TOLEN(15) USING(CTL1)   

This example illustrates how you can create larger records from a subset of smaller sorted records.

The CTL1CNTL data set contains:
    OMIT COND=(2,4,ZD,EQ,0)   
    SORT FIELDS=(1,1,CH,A)          
The OLD data set has RECFM=FB and LRECL=5 with these 5-byte records:
C0005
B0000
A0008
I1234
F0053
D0123
H0001
G0000
E0022
The NEW data set will have RECFM=FB and LRECL=15 with these 15-byte records:
A0008C0005D0123
E0022F0053H0001
I1234   

Note that before the records were resized, the two records with 0 in positions 2-5 were omitted, and the remaining records were sorted as directed by the DFSORT control statements in CTL1CNTL. The last output record was padded with blanks on the right to 15 bytes.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014