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 -> Help on HINTS

Help on HINTS

From: millhill <millhill_at_iname.com>
Date: 18 Dec 2001 08:19:36 -0800
Message-ID: <cf39fae4.0112180819.2547340b@posting.google.com>


Hi,

I have a table with approx 50 million rows. One of my developers queries access this table with a set of joins and where clauses. I know that this select-query only gathers rows where a column is not NULL and this is approx just 2% of the total rows. I have an index on this column.

Here's an example:

t1 contains 50 million rows, t2 and t3 are smaller tables.

select *
from t1, t2, t3
where t1.column1 is not null

and t1.id = t2.id
and t2.id = t3.id
and t1.something = something
and t1.something2 = something2

t1.column1 is not null for approx 2% of all rows in t1 and therefore I would like to let oracle use the first where-clause (t1.column1 is not null) and only work with this sub-set for the rest of the clauses and joins. Is this possible?

Thanx,
-Chris Received on Tue Dec 18 2001 - 10:19:36 CST

Original text of this message

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