Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
Use WHEN=GROUP and OUTFIL reporting features,
Code: |
OPTION COPY
INREC IFTHEN=(WHEN=GROUP,KEYBEGIN=(1,18),
PUSH=(19:ID=5),RECORDS=1)
OUTFIL INCLUDE=(19,5,CH,NE,C' '),
REMOVECC,
NODETAIL,
TRAILER1=(C'Total No.of Records = ',
19,5)
|
If you really want the count left-justified and with no leading zeros, you should be able to manage that yourself with WHEN=INIT in INREC or OUTREC. |
|