Manually Refreshing Materialized Views and Creating Refresh Groups in Oracle
Manually Refreshing Materialized Views and Creating Refresh Groups in Oracle
my_group_1 has two views in its group, mv_market_rate and mv_dealer_rate. Both of
these views will be refreshed at an interval of 30 minutes
DBMS_REFRESH - Procedure ADD
my_group_1 now has three views in its group, mv_market_rate, mv_dealer_rate and
mv_borrowing_rate ( the newly added view). All of these views will be refreshed at
an interval of 30 minutes
DBMS_REFRESH - Procedure SUBTRACT
my_group_1 now has two views in its group, mv_dealer_rate and mv_borrowing_rate.
We have removed mv_market_rate from the refresh group, my_group_1.
DBMS_REFRESH - Procedure REFRESH
The CHANGE procedure is used to change the refresh interval of the refresh group.
SQL> execute DBMS_REFRESH.CHANGE(
name => 'my_group_1',
next_date => NULL,
interval => 'sysdate+1/96');
Removes all materialized views from the refresh group and deletes the refresh
group.
Summary
Creating a refresh group helps to club all related views together and thus
refreshes them together. Manual refresh gives us an opportunity to override the
automatic refresh settings.