11gR2
Automatic optimizer statistics collection gathers
optimizer statistics by calling the DBMS_STATS.GATHER_DATABASE_STATS_JOB_PROC
procedure. The GATHER_DATABASE_STATS_JOB_PROC procedure collects statistics on
database objects when the object has no previously gathered statistics or
the existing statistics are stale because the underlying object has been
modified significantly (more than 10% of the rows).
The DBMS_STATS.GATHER_DATABASE_STATS_JOB_PROC is an internal procedure, but it
operates in a very similar fashion to the DBMS_STATS.GATHER_DATABASE_STATS procedure using the GATHER
AUTO option.
The primary difference is that the
DBMS_STATS.GATHER_DATABASE_STATS_JOB_PROC procedure prioritizes the database
objects that require statistics, so that those objects which most need updated
statistics are processed first. This ensures that the most-needed statistics are
gathered before the maintenance window closes.
自动统计信息收集会调用
DBMS_STATS.GATHER_DATABASE_STATS_JOB_PROC
这个proceudre 来进行统计信息收集,之前没有统计信息
或者统计信息过时(stale , 更改超过 10% rows)的objects 都会收集
。
DBMS_STATS.GATHER_DATABASE_STATS_JOB_PROC 是 sys
下的内部procedure, 它类似 DBMS_STATS.GATHER_DATABASE_STATS 存储
过程(使用 GATHER AUTO 选项)
。
他们的区别 (DBMS_STATS.GATHER_DATABASE_STATS_JOB_PROC 和
DBMS_STATS.GATHER_DATABASE_STATS )是:
前者会将需要
统计信息的 object 进行优先级排序, 以便哪些非常需要更新统计信息的 object 被首先执行,
这个可以确保最需要统计信息的object 可以在维护
时间窗关闭之前被收集统计信息 。
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/35489/viewspace-1364183/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/35489/viewspace-1364183/
在Oracle 11gR2中,自动优化器统计信息收集通过调用DBMS_STATS.GATHER_DATABASE_STATS_JOB_PROC过程实现。该过程会为那些尚无统计信息或已有的统计信息过时(由于对象变动超过10%)的数据库对象收集统计信息。与DBMS_STATS.GATHER_DATABASE_STATS相比,此过程更注重优先处理最需要更新统计信息的对象。

被折叠的 条评论
为什么被折叠?



