Sample Program: Countsrc

Document created by GIAJU01 Employee on Oct 10, 2014Last modified by GIAJU01 Employee on Oct 13, 2014
Version 5Show Document
  • View in full screen mode

The attached application is a batch program which takes the output from a vlsutil library listing and produces a report of every program in the library and the number of lines of code it contains.  It also maintains a total of the lines of code counted.

                                         

SAMPLE JCL...                                               

                                                            

//    *  JOBCARD  *                                        

//PROCLIB  DD DSN=your.proclib,DISP=SHR                    

//STEP1    EXEC PGM=VLSUTIL                                

//STEPLIB DD DSN=your.ipc15.CAVQLOAD,DISP=SHR                

//VLSFILE DD DSN=your.source.library,DISP=SHR              

//AUXPRINT DD DSN=&&TEMP1,DISP=(,PASS),SPACE=(CYL,(5,5),RLSE)

//            UNIT=SYSDA,DCB=(RECFM=FB,LRECL=133,BLKSIZE=1330

//PRTLIST DD SYSOUT=*                                      

//SYSPRINT DD SYSOUT=*                                     

//SYSOUT  DD SYSOUT=*                                      

//SYSIN DD  *                                              

LIBRARY                                                    

//STEP2    EXEC IDLBATCH                                   

//VLSIN DD DSN=&&TEMP1,DISP=(OLD,DELETE)                   

//PRTLIST DD SYSOUT=*                                      

//SYSOUT  DD SYSOUT=*                                      

//AUXPRINT DD SYSOUT=*                                     

//SYSPRINT DD SYSOUT=*                                     

//SYSIN DD *                                               

SEL SYS sys                                                

RUN COUNTSRC VER n                                         

/*

 

You will need to IMPORT the attached program into one of your systems scuh as $ID.

 

//SYSIN    DD *                    

SET IMPORT SYS $ID                 

SET IMPORT DUPLICATE REPLACE       

IMPORT ALL                         

OFF                                

//                                

 

Note:  This program must be run in batch and  can only be run under CA Ideal r15 since it contains $TRANSLATE which is one of

the new functions in CA Ideal r15.

 

                                                      

Attachments

Outcomes