]> granicus.if.org Git - postgresql/commit
Change patternsel (LIKE/regex selectivity estimation) so that if there
authorTom Lane <tgl@sss.pgh.pa.us>
Wed, 20 Sep 2006 19:50:21 +0000 (19:50 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Wed, 20 Sep 2006 19:50:21 +0000 (19:50 +0000)
commitbfd1ffa948e676f0587239a36e71f15690ef2cde
tree0f29dd2001a93fa708142d94f62f940967b09f6b
parent06b33f0ee8481a83f9e62c0fc77ab16afb4aeec1
Change patternsel (LIKE/regex selectivity estimation) so that if there
is a large enough histogram, it will use the number of matches in the
histogram to derive a selectivity estimate, rather than the admittedly
pretty bogus heuristics involving examining the pattern contents.  I set
'large enough' at 100, but perhaps we should change that later.  Also
apply the same technique in contrib/ltree's <@ and @> estimator.  Per
discussion with Stefan Kaltenbrunner and Matteo Beccati.
contrib/ltree/ltree_op.c
src/backend/utils/adt/selfuncs.c
src/include/utils/selfuncs.h