关于dict和v$fixed_table的使用,原文链接
http://www.itpub.net/thread-847572-1-1.html
今天偶然发现一个问题,就是使用dict查找视图的范围比v$fixed_table要广一些,我的测试如下:
SQL> desc v$fixed_table
名称
----------------------------------------- -------- ----------------------------
NAME
OBJECT_ID
TYPE
TABLE_NUM
SQL> select name from v$fixed_table where name like '%TABLESPACE%';
NAME
------------------------------
GV$TABLESPACE
V$TABLESPACE
SQL> select name from v$fixed_table where name like '%QUOTA%';
未选定行
SQL> desc dict
名称
----------------------------------------- -------- ----------------------------
TABLE_NAME
COMMENTS
SQL> select table_name from dict where table_name like '%TABLESPACE%';
TABLE_NAME
------------------------------
DBA_TABLESPACES
USER_TABLESPACES
GV$TABLESPACE
V$TABLESPACE
SQL> select table_name from dict where table_name like '%QUOTA%';
TABLE_NAME
------------------------------
DBA_TS_QUOTAS
USER_TS_QUOTAS
SQL>
通过本次测试发现v$fixed_table不包括静态视图,而dict既包括动态视图也包括静态视图。