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


Example 3

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

RESIZE FROM(IN3) TO(OUT3) TOLEN(3) USING(CTL2)  

This example illustrates how you can break up large records into multiple smaller records.

The CTL2CNTL data set contains:
  OUTFIL FNAMES=OUT3,OMIT=(1,3,CH,EQ,C' '),OVERLAY=(10:X)        
The IN3 data set has RECFM=FB and LRECL=18 with these 18-byte records:
000111222333444555
666777888999

Every 3-byte field in each large IN3 record will be broken up into a single 3-byte field and then padded on the right with blanks to 10-bytes. TOLEN(3) indicates that the resized records will have a length of 3 bytes. OVERLAY=(10:X) expands each resized record to 10 bytes in OUT3. OMIT=(1,3,CH,EQ,C' ') removes any resized records that are completely blank (that is, the two blank resized records resulting from the blanks in positions 13-18 of the second input record).

The OUT3 data set will have RECFM=FB and LRECL=10 with these 10-byte records:
000
111
222
333
444
555
666
777
888
999                

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014