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

Home -> Community -> Usenet -> c.d.o.misc -> Re: automatic refresh of materialized view does not work

Re: automatic refresh of materialized view does not work

From: Frank van Bortel <fvanbortel_at_netscape.net>
Date: Fri, 13 Feb 2004 15:20:19 +0100
Message-ID: <c0ilr3$i6s$1@news3.tilbu1.nb.home.nl>


Matthieu Exbrayat wrote:

> Frank van Bortel wrote:
>

>> Need a db link, need a job (on the MV side, iirc), and
>> need to have job_processes on the remote site...

>
>
> DB LINK exists
> job_processes is set to 10 on both sites. Should be enough...
>
> probably the job is missing. How should I set it ?

What do you do to refresh it manually? dbms_snapshot.refresh(<snapshot>); Put that in a procedure, and create a job to call that procedure:
create procedure refresh_mymv as
begin

   dbms_snapshot.refresh('mmm');
end;
/

Then, create the job in an anonymous pl/sql block: DECLARE
    ln_retval BINARY_INTEGER;
BEGIN

    DBMS_JOB.submit (job =>       ln_retval,
                     what =>      'refresh_mymv;',
		    interval =>  'sysdate + 5/1440'
                    );

END;
/
-- 

Regards,
Frank van Bortel
Received on Fri Feb 13 2004 - 08:20:19 CST

Original text of this message

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