How to use RELDELAY in minutes with DELAYSUB in Seconds
search cancel

How to use RELDELAY in minutes with DELAYSUB in Seconds

book

Article ID: 42090

calendar_today

Updated On:

Products

ESP Workload Automation

Issue/Introduction

How to DELAY a job in Seconds, and use RELDELAY in APPL.

 

Resolution

Example of RELDELAY:

APPL PAYROLL
JCLLIB 'hlq.xxxx.libr'
JOB JOBA
  RUN DAILY
  REL JOBB
JOB JOBB
  RUN DAILY
  RELDELAY 5
ENDJOB

Example using DELAYSUB in seconds.   

The self-completing task in the example below sets the start time for the following job.

JOB DELAYJOB TASK SELFCOMPLETING                                    
   RUN DAILY                                                        
   ESPNOMSG AJ DELAYED.JOB RESET DELAYSUB('REALNOW +                
   PLUS 20 SECONDS') APPL(%ESPAPPL..%ESPAPGEN)                      
   RELEASE ADD(DELAYED.JOB)                                         
ENDJOB                                                              
                                                                    
JOB DELAYED.JOB                                                     
  RUN DAILY
ENDJOB