Oracle: 查看对象的统计信息

优化器会根据对象的统计信息来决定执行计划,因此这个信息很重要。

SQL:

  

–查看表的stats

select * from user_tab_statistics where table_name = ‘STUDENT’

–查看列的stats

select * from user_tab_col_statistics where table_name = ‘STUDENT’

–查看索引的stats

select * from user_ind_statistics where table_name = ‘STUDENT’

Leave a Comment

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.