ALERT: Some images may not load properly within the Knowledge Base Article. If you see a broken image, please right-click and select 'Open image in a new tab'. We apologize for this inconvenience.

z/OS JCL substitution not working correctly

book

Article ID: 88141

calendar_today

Updated On:

Products

CA Automic Workload Automation - Automation Engine

Issue/Introduction

Error Message :
N/A

z/OS JCL substitution not working.

Symbols are not substitured in JCL.

Investigation

Scenario A

JCL:
JS0100 EXEC EDCJRAV1, 
SYS='F', 
SYSY='Y', 
HLQ='ED.', 
JOBNAME='EDFJRAV1', 
RDATE='D&ESPAYY&ESPAMM&ESPADD', 
RTIME='T&ESPAHH&ESPAMN&ESPASS', 
 
Result: IEFC653I SUBSTITUTION JCL - DSN=ED.F.ON.IDR.APPL.D&ESPAYY&ESPAMM&ESPADD.T&ESPAHH&ESPAMN&ESPASS,

Scenario B


JCL:
//SYSIN DD *
 
 UNLOAD CNTLCARDS DB2LOAD SHRLEVEL CHANGE MAXSORTS (4) 
 FORMAT EXTERNAL 
 SELECT * 
 FROM PEDF0.LSCE 
 WHERE 
 CE_EFF_DT > '&&ACNTY' 
 AND CE_MSG_TP_CD = 'H' 

Result: IEFC653I SUBSTITUTION JCL - DSN=ED.F.ON.IDR.APPL.&ACNTY,

Reference
 

 

Cause

Cause type:
By design
Root Cause: In Scenario A JCL interprets it as a string, and not a symbol.
In Scenario B JCL does not support symbol substitution within inline data (SHSIN).

Environment

OS Version: N/A

Resolution

Scenario A:
Remove the ticks or single quotes from the symbol
Example: change from RDATE='D&ESPAYY&ESPAMM&ESPADD' to RDATE= D&ESPAYY&ESPAMM&ESPADD

Scenario B:
In version 2.1 a new DD statement sub-parameter was introduced, called SYMBOLS. You can request JES2 to perform symbol substitution in in-stream dataset.

Fix Status: No Fix

Fix Version(s):
N/A

Additional Information

Workaround :
N/A