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: Materialized view refresh fast without Primary key

Re: Materialized view refresh fast without Primary key

From: Alexander Fatkulin <afatkulin_at_gmail.com>
Date: Fri, 20 Apr 2007 12:25:30 +1100
Message-ID: <49d668000704191825y7109f218yb7fb008442ff62e5@mail.gmail.com>


Try using this instead:

create materialized view temp
refresh fast on demand
with rowid
as select * from mv1.temp ;

On 4/20/07, Chirag DBA <chiragdba_at_gmail.com> wrote:
> Can I refresh materialized view FAST when a primary table doesnt have a
> primary key ?
>
> As per oracle it should work with ROWID option while creating MV logs.
>
> SQL> create table temp(no number);
> Table created.
>
> SQL> create materialized view log on temp with rowid(no) including new
> values;
> Materialized view log created.
>
> -- On secondary site (Same db)
>
> SQL> create materialized view temp refresh on demand as select * from
> mv1.temp ;
> create materialized view temp refresh on demand as select * from mv1.temp
>
> *
> ERROR at line 1:
> ORA-12014: table 'TEMP' does not contain a primary key constraint
>
>
> SQL> create materialized view temp as select * from mv1.temp;
> create materialized view temp as select * from mv1.temp
> *
> ERROR at line 1:
> ORA-12014: table 'TEMP' does not contain a primary key constraint
>
>
> Anyone can tell me what I am doing wrong ?
>
> --
> Cheers,
> ------------------------
> Chirag Majmundar
>
> --
> Cheers,
> ------------------------
> Chirag Majmundar

-- 
Alexander Fatkulin
--
http://www.freelists.org/webpage/oracle-l
Received on Thu Apr 19 2007 - 20:25:30 CDT

Original text of this message

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