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 -> When to Create Index?

When to Create Index?

From: dd <dd_at_dd.com>
Date: Thu, 24 Feb 2005 15:04:30 +0800
Message-ID: <421d9004$1_3@rain.i-cable.com>


In some Oracle's training material, it lists the condition to create index as follows:

  1. A column contains a wide range of values
  2. A column contains a large number of null values
  3. 1 or more columns are frequently used inWHERE clause
  4. The table is large and most queries are expected to retrieve less than 2 to 4 % of the rows.

I understand the rationale behind point 1, 3 only.

For point 2, what do NULL values have to do with index?

For point 4, I guess it is about benefit of index versus full table scan - if the queries return a lot of rows, full table scan isnt a bad idea. But, why it is 2-4% and not some other values? Received on Thu Feb 24 2005 - 01:04:30 CST

Original text of this message

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