FAST DUAL执行计划?

今天发现select sysdate from dual ,它的执行计划与以前不一样,结果如下:

http://www.itpub.net/518843.html


SQL> select sysdate from dual ;
Execution Plan
----------------------------------------------------------
0 SELECT STATEMENT Optimizer=ALL_ROWS (Cost=2 Card=1)
1 0 FAST DUAL (Cost=2 Card=1)

Statistics
----------------------------------------------------------
0 recursive calls
0 db block gets
0 consistent gets
0 physical reads
0 redo size
408 bytes sent via SQL*Net to client
431 bytes received via SQL*Net from client
2 SQL*Net roundtrips to/from client
0 sorts (memory)
0 sorts (disk)
1 rows processed
发现逻辑读与物理读都是0,这个是10g的新特性。

http://julian.dyke.users.btopenworld.com/com/Optimisation/Operations/FastDual.html

FAST DUAL

Description

Provides a more efficient implementation for statements which select a single-row result from DUAL such as SYSDATE, USER or arithmetic calculations

Versions

This operation is implemented in the following versions

10.1.0
10.2.0
Example

This example was developed using Oracle 10.2.0.1 on Linux

This example does not require any table definitions

The statement

 
 

generates the following execution plan

 
 

If the "_fast_dual_enabled" parameter is set to FALSE (default TRUE) then the FAST DUAL operation is disabled. For example

 
 

Now the statement

 
 

generates the following execution plan

 
 

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/267265/viewspace-82829/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/267265/viewspace-82829/

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值