postgresql/src/include
Tom Lane 0ee5a39862 Apply a band-aid fix for the problem that 8.2 and up completely misestimate
the number of rows likely to be produced by a query such as
	SELECT * FROM t1 LEFT JOIN t2 USING (key) WHERE t2.key IS NULL;
What this is doing is selecting for t1 rows with no match in t2, and thus
it may produce a significant number of rows even if the t2.key table column
contains no nulls at all.  8.2 thinks the table column's null fraction is
relevant and thus may estimate no rows out, which results in terrible plans
if there are more joins above this one.  A proper fix for this will involve
passing much more information about the context of a clause to the selectivity
estimator functions than we ever have.  There's no time left to write such a
patch for 8.3, and it wouldn't be back-patchable into 8.2 anyway.  Instead,
put in an ad-hoc test to defeat the normal table-stats-based estimation when
an IS NULL test is evaluated at an outer join, and just use a constant
estimate instead --- I went with 0.5 for lack of a better idea.  This won't
catch every case but it will catch the typical ways of writing such queries,
and it seems unlikely to make things worse for other queries.
2007-08-31 23:35:22 +00:00
..
access Tsearch2 functionality migrates to core. The bulk of this work is by 2007-08-21 01:11:32 +00:00
bootstrap Create a new dedicated Postgres process, "wal writer", which exists to write 2007-07-24 04:54:09 +00:00
catalog Remove the 'not in' operator (!!=). This was a hangover from Berkeley 2007-08-27 01:39:25 +00:00
commands Simplify the syntax of CREATE/ALTER TEXT SEARCH DICTIONARY by treating the 2007-08-22 01:39:46 +00:00
executor Arrange to cache a ResultRelInfo in the executor's EState for relations that 2007-08-15 21:39:50 +00:00
lib Add resetStringInfo(), which clears the content of a StringInfo, and 2007-03-03 19:32:55 +00:00
libpq Move session_start out of MyProcPort stucture and make it a global called MyStartTime, 2007-08-02 23:39:45 +00:00
mb Make JOHAB client only encoding per discussions in pgsql-hackers 2007-04-15 10:56:30 +00:00
nodes Rewrite make_outerjoininfo's construction of min_lefthand and min_righthand 2007-08-31 01:44:06 +00:00
optimizer Rename DLLIMPORT macro to PGDLLIMPORT to avoid conflict with 2007-07-25 12:22:54 +00:00
parser Separate parse-analysis for utility commands out of parser/analyze.c 2007-06-23 22:12:52 +00:00
port Rename DLLIMPORT macro to PGDLLIMPORT to avoid conflict with 2007-07-25 12:22:54 +00:00
postmaster Provide for logfiles in machine readable CSV format. In consequence, rename 2007-08-19 01:41:25 +00:00
regex Wording cleanup for error messages. Also change can't -> cannot. 2007-02-01 19:10:30 +00:00
rewrite Fix a couple of misbehaviors rooted in the fact that the default creation 2007-08-27 03:36:08 +00:00
snowball Tsearch2 functionality migrates to core. The bulk of this work is by 2007-08-21 01:11:32 +00:00
storage Apparently icc doesn't always define __ICC, and it's more correct to 2007-08-05 15:11:40 +00:00
tcop Rename DLLIMPORT macro to PGDLLIMPORT to avoid conflict with 2007-07-25 12:22:54 +00:00
tsearch Cleanup for some problems in tsearch patch: 2007-08-25 00:03:59 +00:00
utils Apply a band-aid fix for the problem that 8.2 and up completely misestimate 2007-08-31 23:35:22 +00:00
c.h Rename DLLIMPORT macro to PGDLLIMPORT to avoid conflict with 2007-07-25 12:22:54 +00:00
fmgr.h Rename DLLIMPORT macro to PGDLLIMPORT to avoid conflict with 2007-07-25 12:22:54 +00:00
funcapi.h Update CVS HEAD for 2007 copyright. Back branches are typically not 2007-01-05 22:20:05 +00:00
getaddrinfo.h Update CVS HEAD for 2007 copyright. Back branches are typically not 2007-01-05 22:20:05 +00:00
getopt_long.h Update CVS HEAD for 2007 copyright. Back branches are typically not 2007-01-05 22:20:05 +00:00
Makefile Allow installation into directories containing spaces in the name. 2005-12-09 21:19:36 +00:00
miscadmin.h Move session_start out of MyProcPort stucture and make it a global called MyStartTime, 2007-08-02 23:39:45 +00:00
pg_config.h.in Support GSSAPI builds where the header is <gssapi.h> and not <gssapi/gssapi.h>, 2007-07-12 14:36:52 +00:00
pg_config.h.win32 Enable IPV6 for all MSVC builds, including the VC6 libpq-only build. 2007-04-16 18:39:19 +00:00
pg_config_manual.h Arrange for large sequential scans to synchronize with each other, so that 2007-06-08 18:23:53 +00:00
pg_trace.h pgindent run for 8.2. 2006-10-04 00:30:14 +00:00
pgstat.h Remove the pgstat_drop_relation() call from smgr_internal_unlink(), because 2007-07-08 22:23:16 +00:00
pgtime.h Fix crash caused by log_timezone patch if we attempt to emit any elog messages 2007-08-04 19:29:25 +00:00
port.h Get dirmod.c on the same page as port.h about whether we use pgsymlink 2007-07-12 23:28:49 +00:00
postgres.h Rename DLLIMPORT macro to PGDLLIMPORT to avoid conflict with 2007-07-25 12:22:54 +00:00
postgres_ext.h Move NAMEDATALEN definition from postgres_ext.h to pg_config_manual.h. It 2007-02-06 09:16:08 +00:00
postgres_fe.h Update CVS HEAD for 2007 copyright. Back branches are typically not 2007-01-05 22:20:05 +00:00
rusagestub.h Update CVS HEAD for 2007 copyright. Back branches are typically not 2007-01-05 22:20:05 +00:00