Am Samstag, 26. Oktober 2002 12:27 schrieb Terry Yapt:
> Hi all,
> I have a basic doubt about indexes... in the next example:
> But if we have an index with the two colums I am using in the WHERE clause,
> why is the planner using seq scan ? (Or perhaps it is because too few rows
> in the table ?)....
First of all, you did not analyze your table (at least you did not mention you did). And an index is never a win for such a small table. I think the planner is fine here to select a seq scan, because your whole table is only 1 database page, so it would be no win to check the index here.
Everything is explained in the manual, check http://developer.postgresql.org/docs/postgres/indexes.html
In response to
pgsql-performance by date
|Next:||From: Tom Lane||Date: 2002-10-26 14:24:52|
|Subject: Re: Basic question about indexes/explain |
|Previous:||From: Terry Yapt||Date: 2002-10-26 10:27:28|
|Subject: Basic question about indexes/explain|