Skip to Main Content
  • Questions
  • Create Scheduler Window dependencies

Breadcrumb

Question and Answer

Chris Saxon

Thanks for the question, Chris.

Asked: October 27, 2020 - 1:53 am UTC

Last updated: November 02, 2020 - 4:16 pm UTC

Version: 12.2 onward

Viewed 1000+ times

You Asked

I am trying to create a Scheduler Window that opens when another closes. The Window I have a dependency on is not mine to control and it's scheduler could change. I've read that Fine Manual (Scheduler Admin guide and DMBS_SCHEDULER), but it doesn't look like this is possible. The only solutions that I could think off are ugly:

1) have a check job that runs in my window to check the schedule of the window I need to run after. If that window schedule has changed, I alter the schedule of mine to follow. The problem is that this is always reactive (as well as a hack).

2) create a dummy job in the window I have a dependency on that is set to stop when the window closes and use events from that to trigger my window somehow (TBD). An even worse hack as I don't want to create jobs in that window.

Ideally I want to be able to set a windows schedule as following another window or have the window somehow raise events. Any version past 12.2 in case I've missed something in a later version.

Any ideas?

Many thanks

and Chris said...

I'm not aware of a built-in way to do this either.

Could you get around this by creating overlapping windows?

If you set the other window to high priority and yours to low, the other window will take effect if both are set to open at the same time. So you just need to create your window to cover all the foreseeable time frames the high priority window could close.

Note the docs do contain this warning on this method:

Although Oracle does not recommend it, windows can overlap.

https://docs.oracle.com/en/database/oracle/oracle-database/19/admin/oracle-scheduler-concepts.html#GUID-9B338464-A8C7-4505-A6AA-A305CC33EC34

So it's not ideal, but potentially better than the other options.



Is this answer out of date? If it is, please let us know via a Comment

More to Explore

Administration

Need more information on Administration? Check out the Administrators guide for the Oracle Database