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: Possible to force an index UNIQUE SCAN in a join ??

Re: Possible to force an index UNIQUE SCAN in a join ??

From: <xhoster_at_gmail.com>
Date: 22 Aug 2005 16:16:52 GMT
Message-ID: <20050822121652.890$ke@newsreader.com>


"Spendius" <spendius_at_muchomail.com> wrote:
> Hi,
> Is it possible to get Oracle to join 2 tables (in a
> nested loop for instance) but using at the same time
> an index UNIQUE SCAN ?

Yes, of course. But sometimes is reports it as a range scan even though it is a unique scan.

> Of course an index declared unique exists on table 2.

And? Are you under the impression that as long as there is an index on some column, it doesn't really matter which column it is?

Xho

> When I hint with INDEX(<table alias> <ind. name>)
> my explain plan always shows a FAST SCAN, whose cost
> is 900 000 times higher than a UNIQUE one (both tables
> contains about 20 millions of rows, an FTS has to
> be performed on the first one). I'm in 8.1.7.4.
>
> Thanks.
> Regards,
> Spendius

-- 
-------------------- http://NewsReader.Com/ --------------------
Usenet Newsgroup Service                        $9.95/Month 30GB
Received on Mon Aug 22 2005 - 11:16:52 CDT

Original text of this message

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