Home » Server Options » Text & interMedia » Re: DBMS_JOB
Re: DBMS_JOB [message #75878] Fri, 26 October 2001 08:47 Go to next message
MarkJ
Messages: 17
Registered: July 1999
Junior Member
A couple of notes.
1. I see no reason to change the nls date format based on your job requirement. Your use of dates is fine.
2. Unlike Unix crontab, dbms_job can not guarantee a job will run on a precise interval without extra code on your part. For example, if your job first runs at 12:00 and runs for 2 minutes, the job will next run at 12:17, then the next one at 12:34.
3. The stored procedure executed by your job either needs to be owned by the same schema that owns the job, or the procedure's owner needs to grant execute on that procedure to the job owner. Since the job is running as pl/sql, the grant must be direct and not done in a role.
-Mark

----------------------------------------------------------------------
Re: DBMS_JOB [message #75947 is a reply to message #75878] Tue, 07 May 2002 23:53 Go to previous messageGo to next message
Dina
Messages: 3
Registered: May 2002
Junior Member
Dear All,
Can u assist me ..?
I want a dbms job submit script that will set the procedure run on 3rd day of the month.
tq
Re: DBMS_JOB [message #75956 is a reply to message #75947] Mon, 03 June 2002 09:55 Go to previous messageGo to next message
unknown
Messages: 12
Registered: April 2001
Junior Member
Examples :

Every day at 12 midnight
'TRUNC(SYSDATE + 1)'

Every day at 8 p.m.
'TRUNC(SYSDATE + 1) + 8/24'

Every Tuesday at 12 noon
'NEXT_DAY(TRUNC(SYSDATE ), ''TUESDAY'' ) + 12/24'

First day of the month at 12 midnight
'TRUNC(LAST_DAY(SYSDATE ) + 1)'

Last day of the quarter at 11 p.m.
'TRUNC(ADD_MONTHS(SYSDATE + 2/24, 3 ), 'Q' ) - 1/24'

Every Monday, Wednesday, and Friday at 9 a.m.
'TRUNC(LEAST(NEXT_DAY(SYSDATE, ''MONDAY"), NEXT_DAY(SYSDATE, "WEDNESDAY"), NEXT_DAY(SYSDATE, "FRIDAY") ) ) + 9/24'
Re: DBMS_JOB [message #75970 is a reply to message #75878] Wed, 24 July 2002 17:44 Go to previous message
Dina
Messages: 3
Registered: May 2002
Junior Member
Hi,
I want to submit the job which will be run at 23:59:59 at the end of the month.

Please assist me about the script...a.s.a.p..

TQ very much,
Dina
Previous Topic: Re: Help w/study questions
Next Topic: Re: ORACLE definition
Goto Forum:
  


Current Time: Thu Mar 28 13:17:32 CDT 2024