Posted: Thu Aug 05, 2004 9:49 am Post subject: Outputting DSN/PDS member with line numbers included
I searched the forums for print+line+number, but could not find anything. I apologize if I'm asking a question that has already been answered...
Is there a way to output a dataset with line numbers as part of the output? I'd like to print some code, essentially a member from my source-lib PDS - OK, I actually, I don't want to physically print it; I want to output it to another DSN, or even to the JES print queue; I can use PRINT ODSN to get it to a downloadable dataset. Anyway, I want the line numbers to be part of the output.
Is there a parm in IKJEFT01 that will "attach" the line numbers? Or maybe there's a way to do that using SyncSort's COPY function?
Or maybe there's another utility I can use?
I can write a NATURAL or COBOL program to do it, but I was hoping to avoid that.....
Joined: 26 Nov 2002 Posts: 12378 Topics: 75 Location: San Jose
Posted: Thu Aug 05, 2004 10:10 am Post subject:
Greg
The following JCl will give the desired results. You need to use parm SEQNUM which will write out the record no for every record. In the following JCL, change the LRECL on outrec fields to your LRECL of the file. At the end of every record , the record no: of 8 bytes is printed. You can adjust the size of the seqnum to your requirement.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum