Jaime Casanova <systemguards@gmail.com> writes:
> But, IMHO, if the table has 143902 and it thinks will retrieve 2610
> (almost 1.81% of the total). it won't be faster with an index?
That's almost one row in fifty. We don't know how wide the table is,
but it's certainly possible that there are order-of-a-hundred rows
on each page; in which case the indexscan is likely to hit every page.
Twice. Not in sequence. Only if the selected rows are pretty well
clustered in a small part of the table is this going to be a win
over a seqscan.
regards, tom lane