Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.tools -> Re: Use what kind index?
cnwy_at_my-deja.com wrote:
>
> I have a table about 1,100,000 records.
> Create Table Card
> (No char(10),
> Client char(15),
> ...
> Status(1),
> )
> Status in ('1','2','3','4','5')
> the status of each card change from '1' to '5'
> the status of new card is '1',the finished status is '5'
> after system runs for a long time,
> '1' 3%
> '2' 5%
> '3' 5%
> '4' 10%
> '5' 77%
> we always do the query with status '4' and '1'
>
> How should I create indexes on the table(normal indexes or bitmap
> indexes)?
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
bitmaps are good for the low cardinality although the updates may cause some locking issues...
possibly look at using null for the 77% and then normal indexing the rest..
HTH
-- =========================================== Connor McDonald http://www.oracledba.co.uk We are born naked, wet and hungry...then things get worseReceived on Sun Aug 13 2000 - 00:00:00 CDT