View previous topic :: View next topic
|
Author |
Message |
obulisankar
New User
Joined: 03 May 2007 Posts: 20 Location: bangalore
|
|
|
|
Hi all,
Could you suggest me to count the number of records in a dataset using File-Aid batch and wite the counts in a new file.
Regards,
Obuli Sankar |
|
Back to top |
|
|
chavansu
New User
Joined: 20 Nov 2008 Posts: 14 Location: California USA
|
|
|
|
Hi,
Can you try this
OPTION COPY OUTFIL TRAILER1=(COUNT=(M11,LENGTH=10))
This is DFSORT utility. |
|
Back to top |
|
|
gcicchet
Senior Member
Joined: 28 Jul 2006 Posts: 1702 Location: Australia
|
|
|
|
Hi,
using FILEAID you can obtain the count from the SYSPRINT statement.
If you need to reformat the output, just write the SYSPRINT to a dataset and then reformat it.
Gerry |
|
Back to top |
|
|
Anuj Dhawan
Superior Member
Joined: 22 Apr 2006 Posts: 6250 Location: Mumbai, India
|
|
|
|
Hi,
Just extending the reply from Gerry, use the below JCL
Code: |
//JS10 EXEC PGM=FILEAID,REGION=6M
//STEPLIB DD DISP=SHR,DSN=XXX.XXXX.LINKLIB
//SYSPRINT DD SYSOUT=*
//SYSLIST DD SYSOUT=*
//DD01 DD DSN=files whose recorsd neded to counted,
// DISP=SHR
//SYSIN DD *
$$DD01 TALLY
/*
//* |
and check the SYSPRINT. |
|
Back to top |
|
|
|