Page 1 of 1

WHAT IS THE UTILITY TO PRINT OUT RECORDS OF A FILE

PostPosted: Mon Dec 08, 2008 12:22 pm
by chatwithbee
here is the question
Print off the first 11 records of this file (#9), double spaced.
i was told there is utility to do that. what is it and what is the code.

Re: WHAT IS THE UTILITY TO PRINT OUT RECORDS OF A FILE

PostPosted: Mon Dec 08, 2008 10:05 pm
by Frank Yaeger
One utility you can do this with is DFSORT using a job like the one below. I assumed your input file has RECFm=FB and LRECL=80, but the job can be changed appropriately for other attributes:

//S1    EXEC  PGM=ICEMAN
//SYSOUT    DD  SYSOUT=*
//SORTIN DD DSN=...  input file (FB/80)
//SORTOUT DD SYSOUT=*
//SYSIN    DD    *
  OPTION COPY,STOPAFT=11
  OUTFIL REMOVECC,BUILD=(/,1,80)
/*