git.postgresql.org Git - postgresql.git/commit

git projects / postgresql.git / commit
? search:
summary | shortlog | log | commit | commitdiff | tree
(parent: 873ea9e) | patch
Fix miscomputation of direct_lateral_relids for join relations.
2020年11月30日 17:22:43 +0000 (12:22 -0500)
2020年11月30日 17:22:43 +0000 (12:22 -0500)
commit b1738ff6ab73203cbbc02d7fb82941dbc061d301
Fix miscomputation of direct_lateral_relids for join relations.

If a PlaceHolderVar is to be evaluated at a join relation, but
its value is only needed there and not at higher levels, we neglected
to update the joinrel's direct_lateral_relids to include the PHV's
source rel. This causes problems because join_is_legal() then won't
allow joining the joinrel to the PHV's source rel at all, leading
to "failed to build any N-way joins" planner failures.

Per report from Andreas Seltenreich. Back-patch to 9.5
where the problem originated.

Discussion: https://postgr.es/m/87blfgqa4t.fsf@aurora.ydns.eu
src/backend/optimizer/util/placeholder.c diff | blob | blame | history
src/test/regress/expected/join.out diff | blob | blame | history
src/test/regress/sql/join.sql diff | blob | blame | history
This is the main PostgreSQL git repository.
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /