Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: Replacing crons with jobs...
create or replace procedure my_cron_job (...) as
begin
lsz_dy := to_char(sysdate,'D');
lsz_tm := to_char(sysdate,'HH24');
if (lsz_dy < 6) and (lsz_tm between 8 and 19) then
do_something_here;
end if;
end my_cron_job;
/
Raj
-----Original Message-----
Sent: Monday, May 19, 2003 4:07 PM
To: Multiple recipients of list ORACLE-L
My initial thought on this is that it would require multiple jobs (one
job for each hour, for each day).
However, it might be simpler to create one single job which runs every
hour every day and have the code built in to check the date (day and
time) and if within certain criteria, do the work, if not do nothing.
>>> joseluis_delgado_at_yahoo.com 05/19/03 01:06PM >>> List...
How can I translate this:
CRONTAB:
00 8-19 * * 1,2,3,4,5
/litoral/oracle/admin/get_users.sh
to Oracle with DBMS_JOB?
I mean: I got confused at the time when I tried to program a job from certain days at certain hours (intervals).
ie: monday to friday from 8:00AM to 19:00 PM every hour.
of course, the *.sh file, connect to Oracle and executes a *.sql script file.
Can you give a bit of help!
TIA
JL
Fat City Network Services -- 858-538-5051 http://www.fatcity.com San Diego, California -- Mailing list and web hosting services ---------------------------------------------------------------------To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
--
Please see the official ORACLE-L FAQ: http://www.orafaq.net
--
Author: Darrell Landrum
INET: DLANDRUM_at_zalecorp.com
Fat City Network Services -- 858-538-5051 http://www.fatcity.com San Diego, California -- Mailing list and web hosting services ---------------------------------------------------------------------To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
--
Please see the official ORACLE-L FAQ: http://www.orafaq.net
--
Author: Jamadagni, Rajendra
INET: Rajendra.Jamadagni_at_espn.com
Fat City Network Services -- 858-538-5051 http://www.fatcity.com San Diego, California -- Mailing list and web hosting services ---------------------------------------------------------------------To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).