Db2 Tools for z/OS

 View Only

Db2 Log Analysis Tool - JCL Simplification

By Tom Crocker posted Mon November 09, 2020 05:38 AM

  

This blog looks at JCL Simplification that has been delivered in Db2 Log Analysis Tool recently through the maintenance stream via PH27980. This feature allows a user to configure a Log Analysis Tool JCL without using the ISPF panels, instead using a JSON file for the parameters.  Note that the same information is now available in the library under Db2 Log Analysis Tool. 

Currently, when a user wants to use the Db2 Log Analysis Tool they have to proceed through the ISPF panels, selecting and changing various parameters to generate the JCL that will be executed to produce the required results.

 

This JCL consists of one or more steps based upon parameters that are described in the various DD statements such as DATAIN & FILTERS. These visible parameter can be easily edited to change tables and log ranges.

 

But there are parameters that are hardcoded in the MODEFILE, therefore a user will have to recreate the entire JCL file if they want to change any values in this binary file, and this is done through the ISPF panels. There are also parameters that cannot be changed as it will change the JCL structure, such as processing mode, these would need the ISPF panels to be used again.

 

This enhancement enables the user to hold the parameter files in JSON format that can be easily edited and understood.

 

To create the JSON file then select the required value in the ‘User Settings' of the product

 

The options are

  • N – Standard JCL job with MODEPARM and MODE35
  • Y – Store all available parameters, including processing mode and product activity
  • S – Short list – only store used parameters and omit defaults

 

By selecting ‘Y’ all parameters are stored which allows a job to be easily parameterized.

 

This parameter is also available in the Quick Start user Settings, although the user can only have the short version of the JSON file or standard JCL.

 

 

There is an additional option in the profile panels allowing a JSON file to generated from previously created profiles, allowing flexibility to convert existing jobs.

 

 

By selecting option ‘P’ JCL is generated with the corresponding JSON file allocated via the JSONIN DD Statement, examples of the JSON file are shown below

 

 

The file will consist of three parts that describe each unit of Log Analysis Tool functionality:

  • Audit mode will provide the process of reports generation (both general and/or details reports).
  • Recover mode will provide the process of UNDO/REDO SQL generation and dynamic SQL execution.
  • Replicate mode will provide the process of LOADFILE generation.

It will not contain any filtering data, a Filter File will be used to store all the filters, and only the dataset name will be included into the JSON file.

 

As a result of this enhancement then there is no requirement to use the ISPF panels to change a few options. For instance, if the user wanted to change the output type from Detailed to Summary then the ‘output flag’ attribute needs to be changed from D to S.

 


Similarly, if the user wanted to generate Undo SQL then they would need to change the ‘generate SQL’ flag to Undo and submit the job.



A dataset definition section in the full JSON file is generated that describes all datasets that can be used during the run. This does not mean that all the datasets will be allocated during processing, the datasets are allocated as required by the processing requested. Datasets allocation can be overridden in this section, and if any file definition is deleted from the JSON then Log Analysis Tool will use the default settings when allocating the dataset.

With this enhancement the need to regenerate Log Analysis Tool JCL using the ISPF panels is reduced dramatically with the introduction of the JSON file format.

​​
#Db2Toolsforz/OS
0 comments
21 views

Permalink