Omitting DSNAME for a temporary data set can cause a JCL error when rerunning using Encore
search cancel

Omitting DSNAME for a temporary data set can cause a JCL error when rerunning using Encore

book

Article ID: 54714

calendar_today

Updated On:

Products

ESP Workload Automation

Issue/Introduction

Sample JCL

//*---------------------------------------------------       
//STEP10   EXEC PGM=IEFBR14                                  
//*---------------------------------------------------       
//SORT1    EXEC PGM=IEFBR14                                  
//SORTOUT  DD   DISP=(NEW,PASS),                             
//          LRECL=80,RECFM=FB,                               
//          SPACE=(TRK,(1,1)),                               
//          UNIT=SYSDA                                       
//*---------------------------------------------------       
//PRINT    EXEC PGM=IEFBR14                                  
//REPORTS  DD   DISP=(OLD,DELETE,DELETE),DSN=*.SORT1.SORTOUT 
//FILES    DD   DISP=SHR,DSN=hlq.dataset.name - did not exist during the initial run; caused a JCL error; create before rerun to remove this error.                    
//*---------------------------------------------------       
//STEP40   EXEC PGM=IEFBR14                                  
//    

Environment

Component: ESP Encore

Cause

If DSNAME is omitted in the DD statement for a temporary data set which is passed to another step and Encore chooses to restart the job in the other step, 
Encore is presently unable to detect that an earlier step needs to create the temporary data set. Encore's EXH (execution history) data for the previous run will 
indicate that earlier step created a data set with a system-assigned DSNAME such as SYS.TEMP1, but the system control blocks at rerun time will show that the 
chosen step refers to the system-assigned DSNAME=SYS1.TEMP2. If SYS1.TEMP2 does not exist and the Encore step's SYSIN data set contains 
PREDICT DSNOTFOUND(NO), the rerun will fail with a JCL error in the chosen step.

An online Encore restart analysis would show that Encore intends to restart the earlier step. The reason an online simulation is able to determine this, while a batch 
restart cannot, is that the online analysis assumes that a job's JCL is identical to the JCL of the previous run (i.e. that the temporary data set will continue to have DSNAME=SYS1.TEMP1 in a rerun.)

Resolution

Manually specify the desired start step for the rerun. 
For future runs, modify the JCL to specify a DSNAME for the temporary SORTOUT data set.