postgresql/src/backend/optimizer/path
Tom Lane 719012e013 Add some defenses against constant-FALSE outer join conditions. Since
eval_const_expressions will generally throw away anything that's ANDed with
constant FALSE, what we're left with given an example like

select * from tenk1 a where (unique1,0) in (select unique2,1 from tenk1 b);

is a cartesian product computation, which is really not acceptable.
This is a regression in CVS HEAD compared to previous releases, which were
able to notice the impossible join condition in this case --- though not in
some related cases that are also improved by this patch, such as

select * from tenk1 a left join tenk1 b on (a.unique1=b.unique2 and 0=1);

Fix by skipping evaluation of the appropriate side of the outer join in
cases where it's demonstrably unnecessary.
2008-08-17 19:40:11 +00:00
..
Makefile Refactor backend makefiles to remove lots of duplicate code 2008-02-19 10:30:09 +00:00
allpaths.c Rearrange the querytree representation of ORDER BY/GROUP BY/DISTINCT items 2008-08-02 21:32:01 +00:00
clausesel.c Clean up the loose ends in selectivity estimation left by my patch for semi 2008-08-16 00:01:38 +00:00
costsize.c Clean up the loose ends in selectivity estimation left by my patch for semi 2008-08-16 00:01:38 +00:00
equivclass.c Rearrange the querytree representation of ORDER BY/GROUP BY/DISTINCT items 2008-08-02 21:32:01 +00:00
indxpath.c Implement SEMI and ANTI joins in the planner and executor. (Semijoins replace 2008-08-14 18:48:00 +00:00
joinpath.c Implement SEMI and ANTI joins in the planner and executor. (Semijoins replace 2008-08-14 18:48:00 +00:00
joinrels.c Add some defenses against constant-FALSE outer join conditions. Since 2008-08-17 19:40:11 +00:00
orindxpath.c Implement SEMI and ANTI joins in the planner and executor. (Semijoins replace 2008-08-14 18:48:00 +00:00
pathkeys.c Rearrange the querytree representation of ORDER BY/GROUP BY/DISTINCT items 2008-08-02 21:32:01 +00:00
tidpath.c Restructure some header files a bit, in particular heapam.h, by removing some 2008-05-12 00:00:54 +00:00