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: Query optimization

Re: Query optimization

From: Jonathan Lewis <jonathan_at_jlcomp.demon.co.uk>
Date: Fri, 2 Nov 2001 11:14:54 -0000
Message-ID: <1004699528.15260.0.nnrp-10.9e984b29@news.demon.co.uk>

Use EXPLAIN PLAN to check the execution path.

Possibly with multiple CAT.NAMEs you switch from an indexed access to a tablescan.

If so, it is possible that adding the hint /*+ use_concat */ may make Oracle treat the query as several 'one-name' queries, which MAY be faster.

--
Jonathan Lewis
http://www.jlcomp.demon.co.uk

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

Author of:
Practical Oracle 8i: Building Efficient Databases

Screen saver or Life saver: http://www.ud.com
Use spare CPU to assist in cancer research.

Spike wrote in message <25e4dd8c.0111020249.1d3cb10f_at_posting.google.com>...

>I have query in the form:
>
>SELECT 'blah'
>
>FROM table
>
>WHERE
>(conditions)
>
>AND
>
>(CAT.NAME = 'eg1'
> OR
>CAT.NAME = 'eg2'
> OR
>CAT.NAME = 'eg3'
> OR
>CAT.NAME = 'eg4'
> OR
>
>etc
>)
>
>
>Any ideas on how I can make it faster?
>When I query 1 cat.name it is fast, but adding more slows it down.
>
>Any ideas?
>
>Spike
Received on Fri Nov 02 2001 - 05:14:54 CST

Original text of this message

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