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 / sorting performance issue

Re: order by / sorting performance issue

From: James <thanatic_at_telstra.com>
Date: 30 Jul 2002 08:23:52 -0700
Message-ID: <7377f06c.0207300723.1cd2047d@posting.google.com>


Hi,

Um, I tried this other method I found on the group:

select * from (
 select * from carsales_view where make_id=10 order by make_name,model_name )
where rownum < 30;

Checkouted the plan and it said something about STOP KEY, anyway...

It gave me the perfomance hit I wanted. I've been using this technique a bit in ad-hoc queries lately but I gave it a go in our application and it worked great.

Also when I tried my hint (see first message) I found that it was only usefull for a couple of qrys in the application, so I specified a second index in the query. But trick seems to be getting Oracle to choose the best index...

I need "stats" for that? Analyze table?

Regards,
James

ps Gold, Silver, Bronze in the Womens marathon was pretty special. Received on Tue Jul 30 2002 - 10:23:52 CDT

Original text of this message

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