Use CA JCLCHECK Workload Automation JCLNEAT feature to make changes to entire JCL library.

Document ID : KB000022912
Last Modified Date : 14/02/2018
Show Technical Document Details

Introduction:

CA JCLCheck Workload Automation has a functionality known as JCLNeat to alter JCL statements.  This Knowledge Document provides examples on how to make JCL changes to an entire JCL library with the use of the 'global string replacement' (GSR) method.


Instructions:

Use the ‘global string replacement’ (GSR) with the JCLNEAT feature will allow you to make changes to the JCL.  Below are examples.

A most common need for the use of GSR is to change UNIT device types. In the example below, all occurrences of TAPE will be replaced with CART for all the JCL members that reside in JCL.LIB. The new JCL members with CART will be written to JCL.LIB.NEW data set.

//JSTEP1 EXEC CAZ1NEAT
//PDSIN   DD DISP=SHR,DSN=JCL.LIB
//PDSOUT  DD DISP=OLD,DSN=JCL.LIB.NEW
//JCLNOPTS   DD *
FORMAT=Y
INLIB=PDS
OUTLIB=PDS
//GSRCNTL DD *
|TAPE|REPL|
|CART|

Another common need is changing data set names. In the example below, all data set PAYROLL.TEST.INPUT will be changed to PAYROLL.PROD.INPUT.

//JSTEP1 EXEC CAZ1NEAT
//PDSIN   DD DISP=SHR,DSN=JCL.LIB
//PDSOUT  DD DISP=OLD,DSN=JCL.LIB.NEW
//JCLNOPTS   DD *
FORMAT=Y
INLIB=PDS
OUTLIB=PDS
//GSRCNTL DD *
|PAYROLL.TEST.INPUT|REPL|
|PAYROLL.PROD.INPUT|


Multiple GSRCNTL statements may be combined. GSR feature may be combined with other JCLNEAT feature such as KEYWORD reordering and other reformatting functions. For additional reading, refer to CA JCLCheck Workload Command Reference Guide - chapter 5: Using JCLNEAT.

As best practice after performing JCLNEAT functions, use CA JCLCheck WA to verify that the changes did not cause errors.


Additional Information:

CA JCLCheck Workload Command Reference Guide - chapter 5: Global String Replacement.


As always, please contact CA Technologies support for CA JCLCheck if you have further questions.