Home » SQL & PL/SQL » SQL & PL/SQL » How can I stop a job at a particular time.
How can I stop a job at a particular time. [message #244267] Tue, 12 June 2007 03:42 Go to next message
abhishek.jain
Messages: 4
Registered: June 2007
Junior Member
Hi all,

I want to run a procedure everyday at 9:30 in the morning
and stop that procedure at 5:00 P.M. I know we can
start the procedure at a particular time with the help
of dbms_job. But how to stop procedure at a particular time??
Please help

Thanks in advance



Re: How can I stop a job at a particular time. [message #244268 is a reply to message #244267] Tue, 12 June 2007 03:49 Go to previous messageGo to next message
sanka_yanka
Messages: 184
Registered: October 2005
Location: Kolkata
Senior Member

You can put a new schedular at 5:00 p.m and can remove the job using dbms_job.remove.

For better clarification please visit the site
http://www.psoug.org/reference/dbms_job.html

Thanks

Sanka
Re: How can I stop a job at a particular time. [message #244271 is a reply to message #244267] Tue, 12 June 2007 04:00 Go to previous messageGo to next message
Michel Cadot
Messages: 64103
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Use dbms_scheduler with a window defined on 9:30 and 17:00 for your job.

Daniel Morgan's Library contains an example: http://www.psoug.org/reference/dbms_scheduler.html

There is also Oracle documentation.

Regards
Michel
Re: How can I stop a job at a particular time. [message #244272 is a reply to message #244267] Tue, 12 June 2007 04:01 Go to previous message
TonSchoen
Messages: 24
Registered: June 2007
Junior Member
I don't what the job is doing, but I'm sure there's something repeating in it. You can test in the repeating part, what time it is. In case it's later than 17:00 then exit the repeat part and leave the job in a natural way.
Previous Topic: Conditional Selection
Next Topic: Why true argument is used in Raise_application_error?
Goto Forum:
  


Current Time: Sun Dec 04 16:20:58 CST 2016

Total time taken to generate the page: 0.09942 seconds