Ok. I got it.
The SQL was parsed 4 times and executed 4 times. The CPU time was 5.33. So the average CPU time was 1.33 seconds and it did 2.5 Miilion LIOs.Code:Now look at the tkprof output: call count cpu elapsed disk query current rows ------- ------ -------- ---------- ---------- ---------- ---------- ---------- Parse 4 0.01 0.01 0 0 0 0 Execute 4 0.00 0.00 0 0 0 0 Fetch 4 5.44 5.31 0 2585652 0 4 ------- ------ -------- ---------- ---------- ---------- ---------- ---------- total 12 5.45 5.33 0 2585652 0 4
Second, there is a huge difference between autotrace explain plan and tkprof output row source. Why? Either statistics are missing on tables and indexes or some init parameters are not set correctly. What's the value for optimizer_mode you set?
As I said earlier, the least number of rows was returned by CB_STANDARD table. Make this as driving table.
Use LEADING hint. Post the autotrace plan and tkprof output. Attach the entire trace file.
Tamil




Reply With Quote