Search code examples
oracleplsqlschedulingjobs

When is the interval parameter of dbms_job.submit reevaluated?


In Oracle we can submit a job to the job queue using the following code:

DECLARE
    X   NUMBER;
BEGIN
    SYS.DBMS_JOB.SUBMIT (
        job         => X,
        what        => 'SYSTEM.INSERTDATE;',
        next_date   => SYSDATE,
        interval    => 'SYSDATE+0.1/(24*60)'
    );
    COMMIT;
END;

Now my question is when the interval parameter is reevaluated? Before the job execution or after the job execution?


Solution

  • Refer to: http://download.oracle.com/docs/cd/B19306_01/appdev.102/b14258/d_job.htm

    interval

    Date function, evaluated immediately before the job starts running.