首页 > Linux操作系统 > Linux操作系统 > oracle统计


原创 Linux操作系统 作者:syzxlyx_cu 时间:2009-09-28 11:06:26 0 删除 编辑

In Oracle9i, no system statistics are available per default. This means that, by default, the cost model is used. As of Oracle Database 10g, a default set of system statistics is always lable. As a result, by default, the CPU cost model is used. Actually, as of Oracle Database  the only way to use the I/O cost model is to specify the hint no_cpu_costing at the SQL ement level. In all other cases, the query optimizer uses the CPU cost model.
System statistics are stored in the data dictionary table aux_stats$. Unfortunately, no data dictionary view is available to externalize them.
To gather noworkload statistics, you set the parameter gathering_mode of the procedure gather_system_stats to noworkload, as shown in the following example:
dbms_stats.gather_system_stats(gathering_mode => 'noworkload'); In Oracle9i, even if they are gathered, no statistics are stored in the data dictionary.
Only the column status in aux_stats$ is set to NOWORKLOAD.
Table 4-4.  Data Dictionary Views Showing Object Statistics of Relational Tables
Object   Table/Index-Level Statistics        Partition-Level Statistics                             Subpartition-Level Statistics
Tables   user_tab_statistics                 user_tab_partitions*                                  user_tab_statistics
         user_tables*                       user_tab_statistics                                     user_tab_subpartitions*

Columns user_tab_col_statistics            user_part_col_statistics                                  user_subpart_col_statistics
           user_tab_histograms             user_part_histograms                                       user_subpart_histograms
Indexes user_ind_statistics                user_ind_statistics                                       user_ind_statistics                     
        user_indexes*                       user_ind_partitions*


来自 “ ITPUB博客 ” ,链接:,如需转载,请注明出处,否则将追究法律责任。

下一篇: Oracle 分析函数
请登录后发表评论 登录


  • 博文量
  • 访问量