Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: HELP: DBMS_JOB QUESTION
Christopher Beck wrote:
> Since the interval time is
> determined before the job runs, you need to come up with some formula, that
> takes the slipping start time into account. Something like this should
> do for an interval assuming your initial start time was on the 00th, 15th, 30th,
>
> or 45th minute...
>
> to_date( to_char( sysdate, 'DDMMYYYYHH24' ) || '0000',
> 'DDMMYYYYHH24MISS' )
> + ( trunc( to_char(sysdate,'MI')/15 ) * 15 + 15 )/1440
>
> This will not guarantee that the job will start exactly at that time, but
> it will schedule it to start at the next appropriate time.
>
Thanks for the email.
I did not get what you mean. Is the formula above for DBMS_JOB.SUBMIT's NEXT_DATE parameter?
If so, I donot think it gonna work.
In fact, what I did is:
DBMS_JOB.SUBMIT(:jobno, 'XYZ;',
to_date('19990922154000', 'YYYYMMDDHH24MISS'), 'SYSDATE + 1/96);
I think to_date('19990921154000', 'YYYYMMDDHH24MISS') will do the same kind of thing
with to_date( to_char( sysdate, 'DDMMYYYYHH24' ) || '0000', 'DDMMYYYYHH24MISS' ) + ( trunc( to_char(sysdate,'MI')/15 ) * 15 + 15 )/1440 in your message.
Thanks again. Look forward to your reply.
Huiming Li Received on Tue Sep 21 1999 - 20:17:27 CDT
![]() |
![]() |