You can create a refresh group by executing the MAKE procedure in the DBMS_REFRESH
package, whose calling parameters are shown here:
DBMS_REFRESH.MAKE
(name IN VARCHAR2,
list IN VARCHAR2, |
tab IN DBMS_UTILITY.UNCL_ARRAY,
next_date IN DATE,
interval IN VARCHAR2,
implicit_destroy IN BOOLEAN := FALSE,
lax IN BOOLEAN := FALSE,
job IN BINARY INTEGER := 0,
rollback_seg IN VARCHAR2 := NULL,
push_deferred_rpc IN BOOLEAN := TRUE,
refresh_after_errors IN BOOLEAN := FALSE,
purge_option IN BINARY_INTEGER := NULL,
parallelism IN BINARY_INTEGER := NULL,
heap_size IN BINARY_INTEGER := NULL);
All but the first four of the parameters for this procedure have default values that are usually
acceptable. The list and tab parameters are mutually exclusive. You can use the following
command to create a refresh group for materialized views names LOCAL_EMP and LOCAL_DEPT:
execute DBMS_REFRESH.MAKE
(name => 'emp_group', -
list => 'local_emp, local_dept', -
next_date => SysDate, -
interval => 'SysDate+7');
NOTE
The list parameter, which is the second parameter in the listing, has a
single quote at its beginning and at its end, with none between. In this
example, two materialized views??”LOCAL_EMP and LOCAL_DEPT??”
are passed to the procedure via a single parameter.
Chapter 17: Managing Distributed Databases 623
The preceding command will create a refresh group named EMP_GROUP, with two materialized
views as its members. The refresh group name is enclosed in single quotes, as is the list of members??”
but not each member.
Pages:
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917