Peter Eisentraut <peter_e(at)gmx(dot)net> writes: > OK, first results with this patch are in: The selectivity estimations are > adjusted nicely, but the cost calculation doesn't change at all. Before: I've forgotten the context ... what's the whole query and plan again? And which PG version exactly? regards, tom lane