发表于: 2008.05.01 22:36
分类: 性能优化
出处: http://warehouse.itpub.net/post/777/460914
---------------------------------------------------------------
doc上的原话,随手记录下!
Note that the full table scan is the lowest ranked access path on the list. This means that the RBO always chooses an access path that uses an index if one is available, even if a full table scan might execute faster.
从上面这段话我们知道full table scan 是最低等级的访问路径,那意味着下面列出来的15种访问路径的数字越小等级越高,也就是说使用访问路径的等级越高rbo认为效率越高,当然实际情况可能并非如此。
Understanding Access Paths for the RBO
Using the RBO, the optimizer chooses an execution plan based on the access paths available and the ranks of these access paths. Oracle's ranking of the access paths is heuristic. If there is more than one way to execute a SQL statement, then the RBO always uses the operation with the lower rank. Usually, operations of lower rank execute faster than those associated with constructs of higher rank.
The list shows access paths and their ranking:
RBO Path 1: Single Row by Rowid
RBO Path 2: Single Row by Cluster Join
RBO Path 3: Single Row by Hash Cluster Key with Unique or Primary Key
RBO Path 4: Single Row by Unique or Primary Key
RBO Path 7: Indexed Cluster Key
RBO Path 9: Single-Column Indexes
RBO Path 10: Bounded Range Search on Indexed Columns
RBO Path 11: Unbounded Range Search on Indexed Columns
RBO Path 13: MAX or MIN of Indexed Column











