简单作了一个10053 ,执行计划都一样,可能在具体的例子中会有差别:
SELECT 'D' "DECODE('A','B','C','D')" FROM "SYS"."DUAL" "DUAL"
***************************************
GENERAL PLANS
***************************************
Considering cardinality-based initial join order.
***********************
Join order[1]:DUAL[DUAL]#0
***********************
Best so far: Table#: 0cost: 2.0012card: 1.0000bytes: 0
(newjo-stop-1) k:0, spcnt:0, perm:1, maxperm:80000
*********************************
Number of join permutations tried: 1
*********************************
Final - All Rows Plan:Best join order: 1
Cost: 2.0012Degree: 1Card: 1.0000Bytes: 0
Resc: 2.0012Resc_io: 2.0000Resc_cpu: 7271
Resp: 2.0012Resp_io: 2.0000Resc_cpu: 7271
kkoipt: Query block SEL$1 (#0)
--------------------------------------------------------------------
SELECT CASE 'A'
WHEN 'B' THEN
'C'
ELSE
'D'
END CASE
FROM DUAL
***************************************
GENERAL PLANS
***************************************
Considering cardinality-based initial join order.
***********************
Join order[1]:DUAL[DUAL]#0
***********************
Best so far: Table#: 0cost: 2.0012card: 1.0000bytes: 0
(newjo-stop-1) k:0, spcnt:0, perm:1, maxperm:80000
*********************************
Number of join permutations tried: 1
*********************************
Final - All Rows Plan:Best join order: 1
Cost: 2.0012Degree: 1Card: 1.0000Bytes: 0
Resc: 2.0012Resc_io: 2.0000Resc_cpu: 7271
Resp: 2.0012Resp_io: 2.0000Resc_cpu: 7271
kkoipt: Query block SEL$1 (#0)
|