Re: again on index usage - Mailing list pgsql-hackers

From Tom Lane
Subject Re: again on index usage
Date
Msg-id 20478.1010675231@sss.pgh.pa.us
Whole thread Raw
In response to Re: again on index usage  ("Zeugswetter Andreas SB SD" <ZeugswetterA@spardat.at>)
List pgsql-hackers
"Zeugswetter Andreas SB SD" <ZeugswetterA@spardat.at> writes:
> I cannot really see how 284 rows can have an estimated index cost of 100506 ?

The estimated number of indexscanned rows is more like 50k.  The number
you are looking at includes the estimated selectivity of the
non-indexable WHERE clauses, too.

> What is actually estimated wrong here seems to be the estimated
> effective cache size, and thus the cache ratio of page fetches.

Good point, but I think the estimates are only marginally sensitive
to estimated cache size (if they're not, we have a problem, considering
how poorly we can estimate the kernel's disk buffer size).  It would
be interesting for Daniel to try a few different settings of
effective_cache_size and see how much the EXPLAIN costs change.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Alessio Bragadini
Date:
Subject: Re: Usenet service (was: RC1 time?)
Next
From: Tom Lane
Date:
Subject: Re: seq scan startup cost