命令"/>
关于analyze table命令
[b]analyze table t1 compute statistics for table;analyze table t2 compute statistics for all columns;
analyze table t3 compute statistics for all indexed columns;
analyze table t4 compute statistics;
得出结论,只有我们在analyze table命令中指定了for table或者不指定任何参数的时候,oracle数据库才会给我们统计基于表的统计信息[/b]
analyze TABLE a COMPUTE statistics FOR TABLE;对表做统计分析,仅仅影响all_tables中的相关数据
analyze TABLE b COMPUTE statistics FOR ALL indexed columns;对索引列做统计分析,仅仅影响all_tab_columns中索引列相关数据
analyze TABLE c COMPUTE statistics FOR TABLE FOR ALL indexed columns;对表和索引列做统计分析,影响all_tables中对应表名的相关数据及all_tab_columns中对应 索引列的相关数据
analyze TABLE d COMPUTE statistics;分析表的所有列和表的整体信息,影响all_tables中对应表名的相关数据及all_tab_columns中属于表d的 所有列的相关数据
来源:
analyze table t compute statistics = analyze table t compute statistics for table for all indexes for all columns
for table的统计信息存在于视图
更多推荐
关于analyze table命令
发布评论