【发布时间】:2013-05-18 07:54:04
【问题描述】:
PLAN_TABLE_OUTPUT
--------------------------------------------------------------------------------
Plan hash value: 2822030489
---------------------------------------------------------------------------------------------
| Id | Operation | Name | Rows | Bytes | Cost (%CPU)| Time |
---------------------------------------------------------------------------------------------
PLAN_TABLE_OUTPUT
--------------------------------------------------------------------------------
| 0 | SELECT STATEMENT | | 1 | 46 | 2 (0)| 00:00:01 |
| 1 | TABLE ACCESS BY INDEX ROWID| PURCHASE | 1 | 46 | 2 (0)| 00:00:01 |
|* 2 | INDEX UNIQUE SCAN | PK_PURCHASENO | 1 | | 1 (0)| 00:00:01 |
---------------------------------------------------------------------------------------------
PLAN_TABLE_OUTPUT
--------------------------------------------------------------------------------
Predicate Information (identified by operation id):
---------------------------------------------------
2 - access("PURCHASENO"=9989)
14 rows selected.
谁能给我解释一下这是什么意思?
这是否意味着 Oracle 正在使用索引来执行此查询?
【问题讨论】:
-
PURCHASENO是一个主键,并在其上定义了一个唯一索引,所以是的 - oracle 选择一个索引访问路径。 -
INDEX UNIQUE SCAN不是线索吗?你看过performance tuning guide吗? -
@AlexPoole 是的,我只是想确保完全回答这个问题。
标签: sql oracle sql-execution-plan