]> granicus.if.org Git - postgresql/commit
When a relation has been proven empty by constraint exclusion, propagate that
authorTom Lane <tgl@sss.pgh.pa.us>
Mon, 24 Mar 2008 21:53:12 +0000 (21:53 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Mon, 24 Mar 2008 21:53:12 +0000 (21:53 +0000)
commit6644be6ece53df7b3c71cc65c7c3d406bdf5a95a
tree58ec2d2a5e9bb5d2ba6c08d6dd7320857579456f
parent63995f01edcf0101ea2efa751fb999cb6f5d853f
When a relation has been proven empty by constraint exclusion, propagate that
knowledge up through any joins it participates in.  We were doing that already
in some special cases but not in the general case.  Also, defend against zero
row estimates for the input relations in cost_mergejoin --- this fix may have
eliminated the only scenario in which that can happen, but be safe.  Per
report from Alex Solovey.
src/backend/optimizer/path/allpaths.c
src/backend/optimizer/path/costsize.c
src/backend/optimizer/path/joinpath.c
src/backend/optimizer/path/joinrels.c
src/include/nodes/relation.h