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

Home -> Community -> Usenet -> c.d.o.misc -> Re: When does a query use an Index?

Re: When does a query use an Index?

From: Holger Heidenbluth <keeptool_at_swn.de>
Date: 1997/09/23
Message-ID: <34281B44.679A@swn.de>#1/1

John Smith wrote:
>
> I have looked through all the books I have and can't find a definitive
> answer.
>
> 1. Does a query use an Index when LIKE is used?
>
> 2. Does a query use an Index when an outer join is performed?
>
> 3. Does an Index get used when a view is used? The book says 'under
> certain conditions an Index will not be used' but doesn't say what they
> are.
>
> Can anyone answer these please?
>
> Thanks,
>
> Andy Horne

That's all right what Dan Clamage <clamage_at_mime.dw.lucent.com> wrote in his reply. The explain plan statement shows you the execution plan for a statement.
You may display the execution plan graphically as an outline view after creating the PLAN_TABLE with our Hora tool. (Free trial at www.keeptool.swn.de)
For analysing more SQL statements you can also use the output of Oracle's TKPROF utility. You have to turn on sql_trace in the init.ora file and then restart the rdbms. Then you can switch the sql_trace on for a session by the ALTER SYSTEM command, using a PL/SQL package or also with Hora.

Regards
Holger Heidenbluth

-- 
KeepTool Software GbR      Internet: http://www.keeptool.swn.de
Schützalle 118             EMail   : mailto:keeptool_at_swn.de
D-14169 Berlin             Phone   : +49-172-5272025
[Dr. Jan Dieckmann, Rolf Grünewald, Holger Heidenbluth GbR]
Received on Tue Sep 23 1997 - 00:00:00 CDT

Original text of this message

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