Home » SQL & PL/SQL » SQL & PL/SQL » Sceduling a job to run on the 15th of every month?
Sceduling a job to run on the 15th of every month? [message #10938] Wed, 25 February 2004 01:44 Go to next message
Dylan
Messages: 3
Registered: February 2004
Junior Member
I have a load of reports which need generated on the 15th of every month. I know to use dbms_job but am unsure how to get it to run on 15th every month. Any ideas on how to get these to run on this date would be great. Thanks, Dylan.
Re: Sceduling a job to run on the 15th of every month? [message #10944 is a reply to message #10938] Wed, 25 February 2004 04:38 Go to previous messageGo to next message
ashok
Messages: 32
Registered: July 2000
Member
Try this :
============
VARIABLE jobno number;
BEGIN
DBMS_JOB.SUBMIT (
:jobno, --Job
'procedure_name', -- what to run
to_date('15-mar-04','dd-mon-yy') , -- First run
last_day(sysdate) + 15 ) ; --Interval
commit;
END;
/
Re: Sceduling a job to run on the 15th of every month? [message #10958 is a reply to message #10944] Wed, 25 February 2004 09:33 Go to previous messageGo to next message
Todd Barry
Messages: 4819
Registered: August 2001
Senior Member
And of course that interval parameter needs to be enclosed with single quotes...
Re: Sceduling a job to run on the 15th of every month? [message #10964 is a reply to message #10944] Wed, 25 February 2004 23:51 Go to previous message
Dylan
Messages: 3
Registered: February 2004
Junior Member
Thanks guys thats looking like it may well work.
Previous Topic: What is the meaning of REFERENCES?
Next Topic: Append data to table with update to rows if they exist
Goto Forum:
  


Current Time: Thu Mar 28 19:54:35 CDT 2024