mirror of
https://git.postgresql.org/git/postgresql.git
synced 2024-09-09 11:29:27 +02:00
9ff79b9d4e
This patch takes care of a number of problems having to do with failure to choose valid join orders and incorrect handling of lateral references pulled up from subqueries. Notable changes: * Add a LateralJoinInfo data structure similar to SpecialJoinInfo, to represent join ordering constraints created by lateral references. (I first considered extending the SpecialJoinInfo structure, but the semantics are different enough that a separate data structure seems better.) Extend join_is_legal() and related functions to prevent trying to form unworkable joins, and to ensure that we will consider joins that satisfy lateral references even if the joins would be clauseless. * Fill in the infrastructure needed for the last few types of relation scan paths to support parameterization. We'd have wanted this eventually anyway, but it is necessary now because a relation that gets pulled up out of a UNION ALL subquery may acquire a reltargetlist containing lateral references, meaning that its paths *have* to be parameterized whether or not we have any code that can push join quals down into the scan. * Compute data about lateral references early in query_planner(), and save in RelOptInfo nodes, to avoid repetitive calculations later. * Assorted corner-case bug fixes. There's probably still some bugs left, but this is a lot closer to being real than it was before. |
||
---|---|---|
.. | ||
clauses.h | ||
cost.h | ||
geqo_copy.h | ||
geqo_gene.h | ||
geqo_misc.h | ||
geqo_mutation.h | ||
geqo_pool.h | ||
geqo_random.h | ||
geqo_recombination.h | ||
geqo_selection.h | ||
geqo.h | ||
joininfo.h | ||
pathnode.h | ||
paths.h | ||
placeholder.h | ||
plancat.h | ||
planmain.h | ||
planner.h | ||
predtest.h | ||
prep.h | ||
restrictinfo.h | ||
subselect.h | ||
tlist.h | ||
var.h |