Billy, On second thoughts, you don't even need the IFTHEN statement as you can perform the numeric check in the INCLUDE cond itself.
//SYSIN DD * INCLUDE COND=(19,03,FS,EQ,NUM,AND, 22,01,CH,EQ,C'D') SORT FIELDS=(01,03,CH,A) OUTFIL REMOVECC,NODETAIL, SECTIONS=(01,03, TRAILER3=(' DEPARTMENT ', 01,03, COUNT=(M10,LENGTH=8), ' ARTICLES, TOTAL ITEMS: ', TOT=(102,09,UFF,M10,LENGTH=12))), TRAILER1=('*** TOTAL *** : ', COUNT=(M10,LENGTH=8), ' ARTICLES, TOTAL ITEMS: ', TOT=(102,09,UFF,M10,LENGTH=12)) /* Thanks, Kolusu DFSORT Development IBM Corporation ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN