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: Table scan ....

Re: Table scan ....

From: Ana C. Dent <anacedent_at_hotmail.com>
Date: Thu, 29 Jul 2004 01:04:16 GMT
Message-ID: <Xns9534B7D47E6BASunnySD@68.6.19.6>


raquel_rodriguezus_at_yahoo.com (Raquel) wrote in news:9a73b58d.0407272150.37acf334_at_posting.google.com:

> I have this simple query:
>
> SELECT COUNT(*)
> FROM T1, T2
> WHERE T1.COL1 = T2.COL2
>
> There is a unique index on COL1 (on table T1) and a unique index on
> COL2 (on table T2). Then why does the Explain plan show me that Oracle
> is using a table scan on T1 and T2? Should it not have used indexes on
> both tables?
>
> TIA
> Raquel.

COL1 & COL2 may be different data type;
which requires a conversion/function be applied to one of them; which precludes using this index. Received on Wed Jul 28 2004 - 20:04:16 CDT

Original text of this message

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