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: any ideas for better performance of this query ?

Re: any ideas for better performance of this query ?

From: Niall Litchfield <n-litchfield_at_audit-commission.gov.uk>
Date: Tue, 16 Oct 2001 10:47:54 +0100
Message-ID: <3bcc0262$0$227$ed9e5944@reading.news.pipex.net>


<sweidanz_at_yahoo.com> wrote in message
news:Zryx7.10$cH1.347_at_nsw.nnrp.telstra.net...
> Can you please explain how you read it that way and how you knew its
> cost-based method? If the optimiser is CHOOSE it does not mean Oracle is
> going use the cost-based!! If none of the tables in the query is analyzed,
> oracle is going use the rule-based. right?

Of course you are right. If no stats exist then Oracle has to use the rule based optimiser.So I should have said that stats might be "out of date,innaccurate or non-existent". My real gripe was with the statement "I see you are using RULE. " You could only state this for sure if the explain plan said Optimizer=RULE. Any other value says that Oracle will use the CBO if at all possible. Given that you will get stats for example if you do an import then it is quite likely that stats exist (at least in any test environment where tuning efforts are being made). If I see Optimiser mode choose I assume that the intention is to use the cost based optimiser, and then concentrate as you suggest on whether the stats are appropriate, or indeed the sql.

--
Niall Litchfield
Oracle DBA
Audit Commission UK


>
>
???????????????????????????????????????????????????????????????????????????? ???????
> I don't read it that way.
>
> from the original post
> "
> Execution Plan
> ----------------------------------------------------------
> 0 SELECT STATEMENT Optimizer=CHOOSE
> "
> This says COST based to me. Of course the stats on the tables may well be
> out of date or inaccurate.
>
???????????????????????????????????????????????????????????????????????????? ???
Received on Tue Oct 16 2001 - 04:47:54 CDT

Original text of this message

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