Re: Index on more than one column

From: Timo Haatainen <Timo.Haatainen_at_ttgroup.fi>
Date: 1996/03/20
Message-ID: <314FDFCB.4E82_at_ttgroup.fi>#1/1


Kjetil Skotheim wrote:
>
> If for instance I have done a
>
> create index on person (lastname, firstname)
>
> Will this index be ignored when I only use lastname= in a
> where clause?

If this is the only index on that table then Oracle will use the index. If there are several indexes then Oracle optimizer chooses the 'best' one.

>
> Will this index be ignored when I only use firstname= in a
> where clause?

Yes

>
> (please resond in email if you can).
>
> --
> Kjetil Skotheim, 22239859 (hjemme), 22852823 (jobb)

Timo Haatainen Received on Wed Mar 20 1996 - 00:00:00 CET

Original text of this message