postgresql/src/include/utils
Tom Lane 40608e7f94 When estimating the selectivity of an inequality "column > constant" or
"column < constant", and the comparison value is in the first or last
histogram bin or outside the histogram entirely, try to fetch the actual
column min or max value using an index scan (if there is an index on the
column).  If successful, replace the lower or upper histogram bound with
that value before carrying on with the estimate.  This limits the
estimation error caused by moving min/max values when the comparison
value is close to the min or max.  Per a complaint from Josh Berkus.

It is tempting to consider using this mechanism for mergejoinscansel as well,
but that would inject index fetches into main-line join estimation not just
endpoint cases.  I'm refraining from that until we can get a better handle
on the costs of doing this type of lookup.
2010-01-04 02:44:40 +00:00
..
acl.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
array.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
ascii.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
builtins.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
bytea.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
cash.h 8.4 pgindent run, with new combined Linux/FreeBSD/MinGW typedef list 2009-06-11 14:49:15 +00:00
catcache.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
combocid.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
date.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
datetime.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
datum.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
dynahash.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
dynamic_loader.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
elog.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
errcodes.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
fmgrtab.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
formatting.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
geo_decls.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
guc.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
guc_tables.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
help_config.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
hsearch.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
inet.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
int8.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
inval.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
logtape.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
lsyscache.h When estimating the selectivity of an inequality "column > constant" or 2010-01-04 02:44:40 +00:00
memutils.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
nabstime.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
numeric.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
palloc.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
pg_crc.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
pg_locale.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
pg_lzcompress.h This patch addresses some issues in TOAST compression strategy that 2008-03-07 23:20:21 +00:00
pg_rusage.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
plancache.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
portal.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
ps_status.h Add GUC update_process_title to control whether 'ps' display is updated 2006-06-27 22:16:44 +00:00
rel.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
relcache.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
resowner.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
selfuncs.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
snapmgr.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
snapshot.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
syscache.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
timestamp.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
tqual.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
tuplesort.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
tuplestore.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
typcache.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
tzparser.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
uuid.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
varbit.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
xml.h Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00