-------------------- ---------- ------------------------------ -------------------- ----------------- - - ------------------------------ --------------------
1 zx AAAVs6AAEAAAAJVAAA 8 20170809 15:58:30 I N FE 2814882911093459
2 wl AAAVs6AAEAAAAJVAAB 9 20170809 15:58:30 I N FE 2814882911093459
3 yc AAAVs6AAEAAAAJVAAC 10 20170809 15:58:30 I N FE 2814882911093459
3 yc AAAVs6AAEAAAAJVAAC 11 20170809 15:58:30 U U 08 2814882911093459
3 yc AAAVs6AAEAAAAJVAAC 12 20170809 15:58:30 U N 08 2814882911093459
2 wl AAAVs6AAEAAAAJVAAB 13 20170809 15:58:30 D O 00 2814882911093459
6 rows selected.
Oracle根据数据字典中的信息可以知道表T上建立了三个物化视图,因此,MV_T_ID刷新完之后,不会删除物化视图记录。但SNAPTIME$$列对应的时候修改为MV_T_ID物化视图刷新时的时间
Oracle的数据字典中还保存着每个物化视图上次刷新的时间和当前的刷新状态。
zx@ORA11G>select name,master,last_refresh from user_mview_refresh_times;
NAME MASTER LAST_REFRESH
------------------------------ ------------------------------ -----------------
MV_T_BOTH T 20170809 15:45:10
MV_T_ID T 20170809 15:58:30
MV_T_NAME T 20170809 15:45:05
zx@ORA11G>select mview_name,last_refresh_date, staleness from user_mviews;
MVIEW_NAME LAST_REFRESH_DATE STALENESS
------------------------------ ----------------- -------------------
MV_T_BOTH 20170809 15:45:10 NEEDS_COMPILE
MV_T_ID 20170809 15:58:30 FRESH
MV_T_NAME 20170809 15:45:05 NEEDS_COMPILE