HELP! very high in cpu usage [message #179451] |
Tue, 27 June 2006 08:38 |
alicia
Messages: 12 Registered: June 2006 Location: Malaysia
|
Junior Member |
|
|
Hi experts,
Below is the execution plan for the my query. The cost is okay for me, of course lower is better.
I test to run this query in 10 threads concurrently, the cpu reachs 100% constantly. Why this happend? is because of high in consistent gets? Or bad sql?
Execution Plan
----------------------------------------------------------
0 SELECT STATEMENT Optimizer=CHOOSE (Cost=59 Card=1 Bytes=304)
1 0 SORT (AGGREGATE)
2 1 HASH JOIN (OUTER) (Cost=59 Card=8847 Bytes=2689488)
3 2 NESTED LOOPS (OUTER) (Cost=40 Card=2816 Bytes=751872)
4 3 NESTED LOOPS (OUTER) (Cost=32 Card=2 Bytes=504)
5 4 HASH JOIN (Cost=30 Card=2 Bytes=476)
6 5 HASH JOIN (OUTER) (Cost=27 Card=10 Bytes=1190)
7 6 TABLE ACCESS (BY INDEX ROWID) OF 'PO' (Cost=18
Card=1 Bytes=60)
8 7 NESTED LOOPS (Cost=20 Card=10 Bytes=970)
9 8 REMOTE* (Cost=2 Card=1 Bytes=37) AA_EADM
IN
10 8 INDEX (RANGE SCAN) OF 'IDX_PO' (NO
N-UNIQUE) (Cost=11 Card=10)
11 6 VIEW (Cost=6 Card=389 Bytes=8558)
12 11 SORT (GROUP BY) (Cost=6 Card=389 Bytes=10114
)
13 12 TABLE ACCESS (BY INDEX ROWID) OF 'PO_ACT' (Cost=2 Card=549 Bytes=14274)
14 13 INDEX (RANGE SCAN) OF 'ID_PO_ACT'
(NON-UNIQUE) (Cost=1 Card=547)
15 5 REMOTE* (Cost=2 Card=29 Bytes=3451) AA_EADM
IN
16 4 INDEX (UNIQUE SCAN) OF 'REP_PO_ACT' (UNIQUE) (Cost
=1 Card=1 Bytes=14)
17 3 REMOTE* AA_EADM
IN
18 2 REMOTE* (Cost=4 Card=14703 Bytes=544011) AA_EADM
IN
9 SERIAL_FROM_REMOTE SELECT "USERID","ORGANIZATIONID" FROM "USERS
" "USERS" WHERE ("ORGANIZATIONID")=N
15 SERIAL_FROM_REMOTE SELECT "USERID","LOCATIONCODE","ORGANIZATION
ID" FROM "USER_LOCATION" "USER_LOCAT
17 SERIAL_FROM_REMOTE SELECT "ORGANIZATIONID" FROM "ORGANIZATION"
"ORGANIZATION" WHERE :1=("ORGANIZATI
18 SERIAL_FROM_REMOTE SELECT "ORGANIZATIONID","LOCATIONCODE" FROM
"ORGANIZATION_LOCATION" "ORGANIZATIO
Statistics
----------------------------------------------------------
28 recursive calls
0 db block gets
13697 consistent gets
0 physical reads
0 redo size
380 bytes sent via SQL*Net to client
504 bytes received via SQL*Net from client
2 SQL*Net roundtrips to/from client
1 sorts (memory)
0 sorts (disk)
1 rows processed
Plz advise.
Cheers/
[Updated on: Tue, 27 June 2006 20:39] Report message to a moderator
|
|
|
|
|
|
|
|
|
|
|