Re: [HACKERS] [PATCHES] Minimum selectivity estimate for LIKE 'prefix%'

2008-03-31 Thread Tom Lane
Peter Eisentraut <[EMAIL PROTECTED]> writes: > Am Montag, 31. März 2008 schrieb Tom Lane: >> I've forgotten the context ... what's the whole query and plan again? >> And which PG version exactly? > Please see http://archives.postgresql.org/pgsql-hackers/2008-01/msg00048.php Hm. Now that I think

Re: [HACKERS] [PATCHES] Minimum selectivity estimate for LIKE 'prefix%'

2008-03-31 Thread Peter Eisentraut
Am Montag, 31. März 2008 schrieb Tom Lane: > Peter Eisentraut <[EMAIL PROTECTED]> 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 q

Re: [HACKERS] [PATCHES] Minimum selectivity estimate for LIKE 'prefix%'

2008-03-31 Thread Tom Lane
Peter Eisentraut <[EMAIL PROTECTED]> 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?

Re: [HACKERS] [PATCHES] Minimum selectivity estimate for LIKE 'prefix%'

2008-03-31 Thread Peter Eisentraut
Am Donnerstag, 6. März 2008 schrieb Tom Lane: > What I propose doing about this is a small variant on Peter's original > suggestion: compute the estimated selectivity for > col = 'prefix' > and clamp the result of prefix_selectivity to be at least that. OK, first results with this patch ar