I want to create a job that would run on 2am on the first Sunday in October
for every year, I tried with the below code. But got the error like,
Error report:
ORA-27419: unable to determine valid execution date from repeat interval
ORA-06512: at "SYS.DBMS_ISCHED", line 124
ORA-06512: at "SYS.DBMS_SCHEDULER", line 271
ORA-06512: at line 2
Here's the code for the create job
BEGIN
DBMS_SCHEDULER.CREATE_JOB(job_name => 'To_DST_Australia',
job_type => 'PLSQL_BLOCK',
JOB_ACTION => 'BEGIN
NULL;
END;',
start_date => SYSTIMESTAMP,
repeat_interval => 'FREQ=YEARLY; BYMONTH=OCT; BYDAY=1SUN; BYHOUR=2; BYMINUTE=00; BYSECOND=00',
end_date => NULL,
enabled => TRUE,
comments => '1st Sunday in October');
END;
/
Thanks in advance.
Use a MONTHLY frequency: