Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> Re: oracle-l Digest V4 #21

Re: oracle-l Digest V4 #21

From: Jonathan Lewis <jonathan_at_jlcomp.demon.co.uk>
Date: Sun, 21 Jan 2007 07:25:21 -0000
Message-ID: <037501c73d2d$4fd3ed20$0200a8c0@Primary>

It appears that most of the time is spent in the first line of the plan.

> STAT #1 id=1 cnt=13516 pid=0 pos=1 obj=0 op='SORT GROUP BY (cr=1395707 r=30863
> w=13376 time=141370825 us)'
> STAT #1 id=2 cnt=458474 pid=1 pos=1 obj=0 op='HASH JOIN (cr=21565 r=30850
> w=13376 time=51353476 us)'

To aggregate 458,000 rows down to 13,000 you record an increment of about 90 seconds and 1,374,000 logical I./Os, for a change of only 16 physical reads.

Given the SQL you've shown us, I can't think of a good reason for this. It looks almost as if there is a scalar subquery lurking somewhere in the final steps of your query - but unless it's hidden in some way in one of your views I can't see how that would occur.

You might get a further clue if you start an SQL*Plus session, run the query, and then see what your session stats look like.

Regards

Jonathan Lewis
http://jonathanlewis.wordpress.com

Author: Cost Based Oracle: Fundamentals
http://www.jlcomp.demon.co.uk/cbo_book/ind_book.html

The Co-operative Oracle Users' FAQ
http://www.jlcomp.demon.co.uk/faq/ind_faq.html

--
http://www.freelists.org/webpage/oracle-l
Received on Sun Jan 21 2007 - 01:25:21 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US