The article will describe how
materialized views can be analyzed and optimized to ensure they can be FAST
REFRESHED, through this way refresh time will reduced from more than 5hours to
less than 1hour.
The tools used to perform the FAST
REFRESH analysis are:
– DBMS_MVIEW
– MV_CAPABILITIES_TABLE
The Oracle provided DBMS_MVIEW.explain_mview procedure is used to analyze each of the existing
materialized views FAST REFRESH capabilities and write the results to the MV_CAPABILITIES_TABLE.
The MV_CAPABILITIES
TABLE is created in the owner’s schema by running the following Oracle 9i
script:
SQL> @$ORACLE_HOME/rdbms/admin/utlxmv.sql
Steps:
– Created the necessary materialized view logs for each of the
master tables making sure to include all columns referenced in any of the
materialized view aggregations along with the ROWID,
SEQUENCE, and INCLUDING
NEW VALUES clauses based on the Oracle 9i
documentation FAST REFRESH requirements.
– Created materialized views including the REFRESH
FORCE ON DEMAND option, in order to prepare for the
detailed analysis of the respective FAST
REFRESH
Comments
Post a Comment