cancel
Showing results for 
Search instead for 
Did you mean: 

Launch a job N minutes after another

Former Member
0 Kudos

Hi all,

It is me again, and I have one basic question that I haven't figure out by myself.

How is it possible to constraint a job to execute only a certain period (let's say 15 minutes) after the end of its predecessor ?

I thought that we could use preconditions but these objects can only tell to launch or skip its script and not to wait.

Have you any ideas ?

Thanks,

Regards

Yi Jiang

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Yi,

The more common request is to have a job start x minutes after the start time of the predecessor. This can be achieved in a two-step chain, by applying a time window on the entire chain (which will determine the start of the chain and the first step) and another time window on the call in the second step which opens 15 minutes later than the first time window.

Your request is also possible, for instance:

- create a three step chain with a 15 minute sleep in the middle (not high-tech, but very efficient and clear in the monitor)

- create a three step chain where the second step changes the start time of the third step (still clear in the monitor, and less running jobs)

- create a job with a post running action (see doc) submitting the successor in 15 minutes

Hope this helps,

Anton Goselink.

Former Member
0 Kudos

Thanks Anton for this quick and multiple answers.

I will use the first solution but can you tell me (for information) which pl sql functions from the jcs package you can use to submit the successor in 15 minutes ?

Regards,

Yi Jiang

Former Member
0 Kudos

Hi Yi,

That would be jcs.submit ( 'OWNER.SCRIPT', starttime => sysdate + 15/1440, ... );

Regards,

Anton.

Former Member
0 Kudos

Great !

I didnot know that this function accepts the starttime parameter.

Regards

Yi Jiang

Answers (0)