Re: Job scheduling in 11g
Date: Thu, 17 Jun 2010 05:36:42 -0700 (PDT)
You probably want to look at DBMS_SCHEDULER rather than DBMS_JOBS. DBMS_SCHEDULAR is the new job scheduler and It allows the daisy chaining that you are looking for and direct execution of external jobs from within the database. OEM has an interface into DBMS_SCHEDULER. One word of warning. The new job scheduler has a lot more functionality, and is thus a bit more complex.
Robert G. Freeman
Master Principal Consultant, Oracle Corporation, Oracle ACE Author of various books on RMAN, New Features and this shorter signature line. Blog: http://robertgfreeman.blogspot.com
From: Ravi Madabhushanam <ravi.madabhushanam_at_gmail.com> To: Yechiel Adar <adar666_at_inter.net.il>; Martin Bach <development_at_the-playground.de> Cc: "oracle-l_at_freelists.org" <Oracle-L_at_freelists.org> Sent: Thu, June 17, 2010 3:59:58 AM
Subject: Re: Job scheduling in 11g
Thank you Martin and Adar.
Both these options are promising.
I'm more inclined towards database job chains as it will help me explore other features of database. Ofcourse batch job is always easy. Let me try these options and get back to you.
Thanks a lot for your inputs.
On Thu, Jun 17, 2010 at 1:08 PM, Yechiel Adar <adar666_at_inter.net.il> wrote:
You can do that easily in windows. Just from the top of my head.
>>Each job creates file jobx.ok or jobx.error.
>>file: schedule jobs.cmd
>>if exist job1.error goto :error
>>if exist *.error goto :error
>>if not exist job2.ok go to :recheck
>>if not exist job3.ok go to :recheck
>>if not exist job4.ok go to :recheck
>>if not exist job5.ok go to :recheck
>>if exist job6.error goto :error
>>if exist job7.error goto :error
>>echo batch finished with error.
>>Ravi Madabhushanam wrote:
>>>>We have a requirement to schedule multiple jobs in Oracle 11g (126.96.36.199) on windows. We have multiple jobs which needs to be executed in a specific order serial and parallel.
>>>>Below is the sequence of our jobs.
>>>>Job 1 -- serial
>>>>Job 2 -- parallel
>>>>Job 3 -- parallel
>>>>Job 4 -- parallel
>>>>Job 5 -- parallel
>>>>Job 6 -- serial
>>>>Job 7 -- serial
>>>>After completion of Job1 we need start job 2,3,4 and 5 in parallel. After completion of all jobs 1-5, Job 6 should start. And job 7 should run only after execution of Job6.
>>>>On linux I would have opted for shell scripting for this. But we are on windows now and I'm not really confident about it. I thought DBMS_Job can be used for this.
>>>>Could you guys please share your opinion on how best I can approach this requirement. Is DBMS_JOB the right choice ? do we have any better way to do this.
>>>>Thanks a lot.