Parse CPU to Parse Elapsd非常低
一个UPDATE语句,用info执行,一种两张表,一个数据两千万,一个数据就几十万,从凌晨6点执行到中午12点都执行不完。麻烦帮忙看下,应该是等待,但是我怎么去查看在等待什么。Plan Statistics
[*]% Total DB Time is the Elapsed Time of the SQL statement divided into the Total Database Time multiplied by 100
Stat NameStatement TotalPer Execution% Snap Total
Elapsed Time (ms)9,525,4085.21
CPU Time (ms)8,729,47118.37
Executions0
Buffer Gets209,999,32612.90
Disk Reads1,105,4670.85
Parse Calls10.00
Rows0
User I/O Wait Time (ms)397,107
Cluster Wait Time (ms)0
Application Wait Time (ms)0
Concurrency Wait Time (ms)0
Invalidations0
Version Count3
Sharable Mem(KB)79
Back to Plan 1(PHV: 1618931016)
Back to Top
Execution Plan
IdOperationNameRowsBytesCost (%CPU)Time
0UPDATE STATEMENT 56512 (100)
1 UPDATEDWB_DELIV_DOC_NUM
2 HASH JOIN RIGHT SEMI 18356512 (2)00:11:19
3 TABLE ACCESS FULLTMP_DELIV_DOC_NUM8122404K10 (0)00:00:01
4 TABLE ACCESS FULLDWB_DELIV_DOC_NUM7338K223M56430 (2)00:11:18
5 TABLE ACCESS FULLTMP_DELIV_DOC_NUM16410 (0)00:00:01
[*]dynamic sampling used for this statement
Back to Plan 1(PHV: 1618931016)
Back to Top
Full SQL Text
SQL IdSQL Text
ddrfr4nrshvv3--???? update DWB_DELIV_DOC_NUM t set t.struck_status='??', t.efficient_time = (select efficient_time from tmp_DELIV_DOC_NUM t1 where t1.unit_id = t.disp_unit_id and t1.gdn_num=t.gdn_num) where (t.disp_unit_id, t.gdn_num) in (select unit_id, gdn_num from tmp_DELIV_DOC_NUM)
从感觉上,该sql 可以优化,建议使用sqlhc收集信息,然后上传,进一步分析
页:
[1]