Posted by: nkristanto | October 16, 2008

Create Materialized View Fails with Remote View

While creating a materialized view in a 10.2.0.4 database using a view in a remote 10.2.0.3 database as the base table, the creation failed:

SQL> create materialized view db2_dba_ts_quotas_mv
 build immediate
 refresh with rowid complete on demand
 as select tablespace_name, username, max_bytes
 from dba_ts_quotas@db1;

ERROR at line 1:
ORA-00942: table or view does not exist
ORA-06512: at “SYS.DBMS_SNAPSHOT_UTL”, line 1543
ORA-06512: at line 1

The user used in the database link has SELECT ANY DICTIONARY access in the remote database.

Creation of the same materialized views for other 10.2.0.4 database works. To address this issue, instead of creating materialized view based on sys.dba_ts_quotas, I created a view for sys.dba_ts_quotas for the db link user, and create the materialized view based on this view. It worked fine!

Advertisement

Responses

  1. It is know bug in 10.2.0.3 . These Bugs are fixed in the 10.2.0.4 Patch Set

  2. Raghavan – thanks for the info and for visiting. Regards – Nico

  3. Bonjour!
    try this :

    SQL> create materialized view db2_dba_ts_quotas_mv
    build immediate
    refresh with rowid complete on demand
    as select * from (select tablespace_name, username, max_bytes
    from dba_ts_quotas@db1);


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Categories

Follow

Get every new post delivered to your Inbox.