Oracle Error QSM-02180: no primary key constraint in the master table

Oracle Error Message

QSM-02180: no primary key constraint in the master table

Reason for the Error

The explain_mview assumes that the materialized view is going to be created as the Primary Key materialized view. A Primary Key materialized view can not be created if the base table does not have a primary key constraint.

Solution

Add a primary key constraint to the base table, or create the materialized view as Rowid MV by specifying the WITH ROWID option. If the materialized view is a Rowid MV, then it should be able to do complete refresh and even fast refresh, given that the materialized view log on the master table has a rowid.

Share:

Leave A Reply

Your email address will not be published. Required fields are marked *

You May Also Like

Oracle Error Message ORA-24328: illegal attribute value Reason for the Error The attribute value passed in is illegal. Solution Consult...
Oracle Error Message ORA-01346: LogMiner processed redo beyond specified reset log scn Reason for the Error LogMiner has detected a...
Oracle Error Message ORA-13241: specified dimensionality does not match that of the data Reason for the Error An error occurred...