aboutsummaryrefslogtreecommitdiff
path: root/src/backend/access/transam/xlog.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2015-07-31 19:26:33 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2015-07-31 19:26:33 -0400
commita6492ff8970b06b9e27cc314c7d1aa574fcc7b04 (patch)
treee7e3b9b388c0b1f65c565f135a79ac17114a47be /src/backend/access/transam/xlog.c
parent16c4e6d8dc8fb98cd32d9af473fb06a730fb40d3 (diff)
downloadpostgresql-a6492ff8970b06b9e27cc314c7d1aa574fcc7b04.tar.gz
postgresql-a6492ff8970b06b9e27cc314c7d1aa574fcc7b04.zip
Fix an oversight in checking whether a join with LATERAL refs is legal.
In many cases, we can implement a semijoin as a plain innerjoin by first passing the righthand-side relation through a unique-ification step. However, one of the cases where this does NOT work is where the RHS has a LATERAL reference to the LHS; that makes the RHS dependent on the LHS so that unique-ification is meaningless. joinpath.c understood this, and so would not generate any join paths of this kind ... but join_is_legal neglected to check for the case, so it would think that we could do it. The upshot would be a "could not devise a query plan for the given query" failure once we had failed to generate any join paths at all for the bogus join pair. Back-patch to 9.3 where LATERAL was added.
Diffstat (limited to 'src/backend/access/transam/xlog.c')
0 files changed, 0 insertions, 0 deletions