I did that following this method but it doesn't work right.
The job runs at 730, 930, and 1230 instead of 7, 930, and
12. Why would it do that?
Because you created the LOAD_1 schedule at a time of day when
to_char(sysdate,'MI') returned '30'. :-)
I just - at 07:39 created a LOAD_1 schedule and In Toad, extracted the
next 10 scheduled run times, they were all at 7:39 and 12:39. This
propagates through to the LOAD_MAIN schedule.
Do this to fix it:
dbms_scheduler.create_schedule('LOAD_1', repeat_interval =>
Add a BYMINUTE to the schedule, or alternatively, use the startdate
parameter to set a starting date that include '00' as the minutes. And
it's a timestamp not a date, just for added fun. (I hate timestamps,
especially those with timezones - as this is!)
PS. Yesterday was the first time ever I had to create a schedule (!!!)
and I had exactly the same problem you did - the minutes was all over
the place until I realised that it reflected the fact that the default
start time appears to be systimestamp. So the minutes and seconds part
is simply defaulted to the time that the schedule was created. I found
that by adding either a startdate or a BYMINUTE, I got it to run on the
hour as required - but there's not much I can do about the seconds -
unless I use a startdate with zero seconds.
PPS. This might be useful http://www.packtpub.com/mastering-oracle-scheduler-in-oracle-11g-databas
Information in this message may be confidential and may be legally privileged. If you have received this message by mistake, please notify the sender immediately, delete it and do not copy it to anyone else.
We have checked this email and its attachments for viruses. But you should still check any attachment before opening it.
We may have to make this message and any reply to it public if asked to under the Freedom of Information Act, Data Protection Act or for litigation. Email messages and attachments sent to or from any Environment Agency address may also be accessed by someone other than the sender or recipient, for business purposes.
If we have sent you information and you wish to use it please read our terms and conditions which you can get by calling us on 08708 506 506. Find out more about the Environment Agency at www.environment-agency.gov.uk