Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Query optimisation
Geoff Dewhurst wrote:
>
> Hi,
>
> Even when I use a hint, it still does not want to use that index! I thought
> that a hint would force it to use the index, but that does not seem to be
> the case. Any thoughts?
>
> Geoff
>
> Keith Boulton <boulke_at_globalnet.co.uk> wrote in article
> <3472cca1.506968_at_read.news.global.net.uk>...
> > On 18 Nov 1997 23:24:40 GMT, "Geoff Dewhurst" <Geoff_at_Bass-Soft.com.au>
> > wrote:
> > .....
> > Even using an index the second query would be slower than the first
> > because of the need to perform a table access. You could use the index
> > hint to see the performance with an index e.g.
> >
> > SELECT /*+ INDEX( CLR CLRIDX ) */ CODE FROM CLR WHERE CLRIDX = 1;
> >
I believe the optimizer isn't obligated to use a hint, it's just a "suggestion". I don't know why Oracle doesn't let you explicitly set an execution path. Seems like it would be a benefit. Standard disclaimer - I could be wrong ( happens so often in fact that I'm thinking about getting it tattooed on the forehead.)
Anyway, good luck
Terry
Received on Sun Nov 23 1997 - 00:00:00 CST