Commit 3bef56e
committed
Invent "join domains" to replace the below_outer_join hack.
EquivalenceClasses are now understood as applying within a "join
domain", which is a set of inner-joined relations (possibly underneath
an outer join). We no longer need to treat an EC from below an outer
join as a second-class citizen.
I have hopes of eventually being able to treat outer-join clauses via
EquivalenceClasses, by means of only applying deductions within the
EC's join domain. There are still problems in the way of that, though,
so for now the reconsider_outer_join_clause logic is still here.
I haven't been able to get rid of RestrictInfo.is_pushed_down either,
but I wonder if that could be recast using JoinDomains.
I had to hack one test case in postgres_fdw.sql to make it still test
what it was meant to, because postgres_fdw is inconsistent about
how it deals with quals containing non-shippable expressions; see
https://postgr.es/m/1691374.1671659838@sss.pgh.pa.us. That should
be improved, but I don't think it's within the scope of this patch
series.
Patch by me; thanks to Richard Guo for review.
Discussion: https://postgr.es/m/830269.1656693747@sss.pgh.pa.us1 parent b448f1c commit 3bef56e
File tree
12 files changed
+269
-193
lines changed- contrib/postgres_fdw
- expected
- sql
- src
- backend
- nodes
- optimizer
- path
- plan
- prep
- include
- nodes
- optimizer
12 files changed
+269
-193
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2513 | 2513 | | |
2514 | 2514 | | |
2515 | 2515 | | |
2516 | | - | |
| 2516 | + | |
2517 | 2517 | | |
2518 | 2518 | | |
2519 | 2519 | | |
| |||
2527 | 2527 | | |
2528 | 2528 | | |
2529 | 2529 | | |
2530 | | - | |
| 2530 | + | |
2531 | 2531 | | |
2532 | 2532 | | |
2533 | 2533 | | |
2534 | 2534 | | |
2535 | 2535 | | |
2536 | 2536 | | |
2537 | 2537 | | |
2538 | | - | |
| 2538 | + | |
| 2539 | + | |
2539 | 2540 | | |
2540 | 2541 | | |
2541 | 2542 | | |
2542 | 2543 | | |
2543 | 2544 | | |
2544 | 2545 | | |
2545 | | - | |
2546 | | - | |
2547 | | - | |
| 2546 | + | |
| 2547 | + | |
2548 | 2548 | | |
2549 | | - | |
| 2549 | + | |
2550 | 2550 | | |
2551 | 2551 | | |
2552 | 2552 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
681 | 681 | | |
682 | 682 | | |
683 | 683 | | |
684 | | - | |
| 684 | + | |
685 | 685 | | |
686 | 686 | | |
687 | 687 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
468 | 468 | | |
469 | 469 | | |
470 | 470 | | |
471 | | - | |
472 | 471 | | |
473 | 472 | | |
474 | 473 | | |
| |||
0 commit comments