Query Optimizer Modes【每日一译】--2013-1-24

来源:互联网 发布:知乎精彩问题 编辑:程序博客网 时间:2024/05/19 16:04
Tuning mode
In tuning mode, the optimizer performs additional analysis to check whether the
execution plan produced under normal mode can be further improved. The output of
the query optimizer is not an execution plan, but a series of actions, along with their
rationale and expected benefit for producing a significantly superior plan. When called
under the tuning mode, the optimizer is referred to as the Automatic Tuning
Optimizer. The tuning performed by the Automatic Tuning Optimizer is called

Automatic SQL Tuning.

调试模式

调试模式中,优化器执行额外的分析去核对是否执行计划的产生在普通模式下是否有

进一步的提高。查询优化器的输出不是一个执行计划,而是一系列的动作,使用它们

依据和预估优点去产生一个吸引人的较好的执行计划。当在调试模式下时,优化器作为

自动调试优化器来相关使用。调试通过自动调试优化器叫做自动SQL调优。

Under tuning mode, the optimizer can take several minutes to tune a single statement.
It is both time and resource intensive to invoke the Automatic Tuning Optimizer every
time a query has to be hard-parsed. The Automatic Tuning Optimizer is meant to be
used for complex and high-load SQL statements that have non-trivial impact on the
entire system. The Automatic Database Diagnostic Monitor (ADDM) proactively
identifies high-load SQL statements which are good candidates for Automatic SQL

Tuning.

在自动调试模式下。优化器花费几分钟可以调试一个单独的语句。时间和资源集中去

调用自动调试优化器将执行硬解析每次一个查询。ATO用于复杂和高负载的SQL语句,

这些语句对整个系统产生有价值的影响。ADDM预先确定高负载SQL语句,它是一个

好的选择对于SQL调优。