索引分析后index_stats里没数据?
来源:互联网 发布:施耐德m258编程软件 编辑:程序博客网 时间:2024/04/30 05:12
SQL>
Index analyzed.
no rows selected
转到底部
In thisDocument
Applies to:
Oracle Database - Enterprise Edition - Version 9.2.0.1 to 11.2.0.3[Release 9.2 to 11.2]Information in this document applies to any platform.
***Checked for relevance on 27-Jan-2012***
Symptoms
A sql command 'analyze index validate structure online' does notpopulate index_stats or index_histogram while without the onlineclause it does populate the views.
Testcase
SQL> create table test (id number, text varchar2(9));
SQL> create index test_indx on test(id);
SQL> insert into test values (1, 'A');
SQL> insert into test values (2, 'B');
SQL> insert into test values (3, 'C');
SQL> commit;
SQL> analyze index test_indx validate structure online;
Index analyzed.
SQL> select * from index_stats;
no rows selected
SQL> select * from index_histogram;
no rows selected
SQL> analyze index test_indx validate structure ;
Index analyzed.
SQL> select * from index_stats;
HEIGHT
---------- ---------- ------------------------------
PARTITION_NAME
------------------------------ ---------- ---------- ---------------------
---------- ---------- ----------- ---------- --------------------------
DISTINCT_KEYS MOST_REPEATED_KEY BTREE_SPACEUSED_SPACE
------------- ----------------- ----------- ---------- ----------------------
BLKS_GETS_PER_ACCESS PRE_ROWS
-------------------- ---------- ------------ ------------------------------
1