To Whom May Concern:
I have a FB 133 file that I want to count the occurrences of 3 record types HOLD,WAIT & EXEC which start in column 53. I can accomplish this task with the below JCL.
//STEP001 EXEC PGM=SYNCTOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//IN1 DD DSN=NDMZZZ.TEST,DISP=SHR
//CT DD DSN=NDMZZZ.NDMQUE,DISP=(,CATLG,DELETE),UNIT=TEST,
// DCB=(LRECL=133,RECFM=FB),SPACE=(CYL,(1,1),RLSE)
//TOOLIN DD *
COUNT FROM(IN1) WRITE(CT) TEXT('NDM IN HOLD STATUS IS ') -
EDCOUNT(A1,U10) USING(CTL1)
//CTL1CNTL DD *
INCLUDE COND=(53,4,CH,EQ,C'HOLD')
*************************************************************************************
output
NDM IN HOLD STATUS IS 2
I can get the total counts for 'EXEC' ,'WAIT' & 'HOLD' records, by excuting the above JCL in 3 steps changing the TEXT & INCLUDE parameter to reflect each record type.
Is it possible to capture the record counts for 'EXEC' ,'WAIT' & 'HOLD' in one step?
output
NDM IN HOLD STATUS IS 2
NDM IN WAIT STATUS IS 5
NDM IN EXEC STATUS IS 1