Re: Bug #474: Index using problem - Mailing list pgsql-bugs

From Tom Lane
Subject Re: Bug #474: Index using problem
Date
Msg-id 6987.1002289730@sss.pgh.pa.us
Whole thread Raw
In response to Bug #474: Index using problem  (pgsql-bugs@postgresql.org)
List pgsql-bugs
pgsql-bugs@postgresql.org writes:
>   explain select * from cim where utod_cim_id=0;
>   NOTICE:  QUERY PLAN:
>   Seq Scan on cim  (cost=0.00..6555.41 rows=253633 width=118)

>   The query optimizer does not use my index..

How many rows are there where utod_cim_id=0?  The planner guesses that
there are a lot (253633, to be exact) and concludes that using the index
is not profitable for this query.

            regards, tom lane

pgsql-bugs by date:

Previous
From: Andreas Wernitznig
Date:
Subject: Re: Bug #474: Index using problem
Next
From: Tom Lane
Date:
Subject: Re: Bug #474: Index using problem