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

Home -> Community -> Usenet -> c.d.o.server -> Re: ORDER BY performance problem

Re: ORDER BY performance problem

From: Connor McDonald <connor_mcdonald_at_yahoo.com>
Date: Mon, 09 Aug 1999 22:40:13 +0800
Message-ID: <37AEE84D.FF5@yahoo.com>


Franz Mueller wrote:
>
> Hi,
>
> I have a performance problem with a query that ends with "ORDER BY .."
> Without the ORDER BY it runs really fast. The difference is really big
> (on an answer set with 200 rows). Is there a way to speed up this kind
> of query?
>
> Franz

Some possibilities..

  1. The 200 rows you are getting is the "tip of the iceberg". Many tools will just show you the first "n" records on a result set before proceeding. When you add "order by" the database must get ALL of the records
  2. The "order by" is significantly changing the access method being used. Try "set autotrace on" in SQL Plus or have a read on EXPLAIN PLAN and see how you go.

HTH
--



Connor McDonald
"These views mine, no-one elses etc etc" connor_mcdonald_at_yahoo.com

"Some days you're the pigeon, and some days you're the statue." Received on Mon Aug 09 1999 - 09:40:13 CDT

Original text of this message

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