When the user uses the ESP SUBMIT command in ESP Event definition, like below:
EVENT ID(ESP.EVENTA) SYSTEM(-) REPLACE
SUBMIT 'ESP.JCLLIB(JOBA)'
JCL for JOBA, normally the JOB card is the first statement in the JCL, but for this case, there are statements to define the JOBGROUP.
//JOBGRPX JOBGROUP (xxxxxxx),'TEST-JOBGROUP'//TESTJOB1 GJOB//TESTJOB2 GJOB// AFTER NAME=TESTJOB1//TESTJOB3 GJOB// AFTER NAME=TESTJOB2//JOBGRPX ENDGROUP//JOBA JOB (xxxxxxxx),'TEST-JOB'
The JOB failed with JCL ERROR and HASP148 when submitted by ESP:
IEFC452I DCFI10T1 - JOB NOT RUN - JCL ERROR
....
HASP148 Job group not found
Will ESP simply send the JCL to JES or it may read thru the JCL and skip the statements BEFORE the JOB card?
Component: ESP Workload Automation
Release: ALL
ESP parses the JCL specified on SUBMIT only for the JOB card (and its subcommands), but ignores the statements like JOBGROUP.
Workaround: Use IEBGENER to submit the job with JOBGROUP. Here is an example:
//JOBA JOB//STEP10 EXEC PGM=IEBGENER //SYSUT1 DD DISP=SHR,DSN=ESP.JCLLIB(JOBA) //SYSUT2 DD SYSOUT=(A,INTRDR) //SYSIN DD DUMMY //SYSPRINT DD SYSOUT=*