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 -> Index design question

Index design question

From: <michael_bialik_at_my-deja.com>
Date: Tue, 23 Nov 1999 21:52:14 GMT
Message-ID: <81f2a6$ida$1@nnrp1.deja.com>


Hi.

 I have a claim system :

  CREATE TABLE claim (
    company_id NUMBER(4),
    claim_no NUMBER(12),
    open_date DATE,
    close_date DATE,
    description VARCHAR2(30),
    constraint claim_pk primary key ( company_id, claim_no));

 I need to write a query that performs :

  SELECT * FROM claim
  WHERE company_id = :p1 AND
  ( open_date between :p2 and :p3 OR
    close_date between :p2 AND :p3 );

 What do you think is the best index ( or indexes ) to support  such query?

 TIA. Michael.

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Tue Nov 23 1999 - 15:52:14 CST

Original text of this message

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