Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> Re: how to notify when dbms_job completes?

Re: how to notify when dbms_job completes?

From: Connor McDonald <hamcdc_at_yahoo.co.uk>
Date: Tue, 13 May 2003 21:11:51 -0800
Message-ID: <F001.0059859D.20030513211151@fatcity.com>


A quick dirty home grown solution is:

for i in 1 .. no_of_indexes loop
  dbms_submit.submit(
    index_builder(index_name, power(2,i)); end loop;

where index_builder does:

when 'select sum(log_table)' =
power(2,no_of_indexes+1)-1 then they are all done

hopefully you get what I'm describing here - basically a bit in a bit stream for each index. Even sinpler is to submit a new job which simply queries dba_jobs every 'n' seconds until there are no more 'index_builder' jobs left at which point start the dbms_stats

hth
connor


Connor McDonald
web: http://www.oracledba.co.uk
web: http://www.oaktable.net
email: connor_mcdonald_at_yahoo.com

"GIVE a man a fish and he will eat for a day. But TEACH him how to fish, and...he will sit in a boat and drink beer all day"



Yahoo! Plus
For a better Internet experience
http://www.yahoo.co.uk/btoffer
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: =?iso-8859-1?q?Connor=20McDonald?=
  INET: hamcdc_at_yahoo.co.uk

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).
Received on Wed May 14 2003 - 00:11:51 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US