agora inbox for [email protected]
help / color / mirror / Atom feedRe: Retiring is_pushed_down
9+ messages / 2 participants
[nested] [flat]
* Re: Retiring is_pushed_down
@ 2026-02-04 09:57 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 9+ messages in thread
From: Álvaro Herrera @ 2026-02-04 09:57 UTC (permalink / raw)
To: Richard Guo <[email protected]>; +Cc: Tom Lane <[email protected]>; pgsql-hackers
On 2025-Jan-14, Richard Guo wrote:
> On Fri, Sep 27, 2024 at 5:06 AM Tom Lane <[email protected]> wrote:
> > So I'm worried that the point about lateral refs is still a problem
> > in your version. To be clear, the hazard is that if a WHERE clause
> > ends up getting placed at an outer join that's higher than any of
> > the OJs specifically listed in its required_relids, we'd misinterpret
> > it as being a join clause for that OJ although it should be a filter
> > clause.
>
> I don't quite understand how this could happen. If a WHERE clause is
> placed on an outer join but does not include the outer join's ojrelid
> in its required_relids, then it must only refer to the non-nullable
> side. In that case, we should be able to push this clause down to the
> non-nullable side of the outer join.
>
> Perhaps this issue could occur with a lateral join, but I wasn't able
> to construct such a query.
Has this patch been definitely shot down? Discussion appears to have
stalled with little conclusion.
https://commitfest.postgresql.org/patch/4458/
--
Álvaro Herrera Breisgau, Deutschland — https://www.EnterpriseDB.com/
^ permalink raw reply [nested|flat] 9+ messages in thread
* [PATCH 1/2] Minor cleanup in initialize_change_context().
@ 2026-07-01 12:58 Antonin Houska <[email protected]>
0 siblings, 0 replies; 9+ messages in thread
From: Antonin Houska @ 2026-07-01 12:58 UTC (permalink / raw)
First, use makeNode() to create an instance of ResultRelInfo, like we do
elsewhere in the tree.
Second, pass NULL for the 'partition_root_rri' argument of InitResultRelInfo
instead of 0.
---
src/backend/commands/repack.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/backend/commands/repack.c b/src/backend/commands/repack.c
index 4d177c868bb..c9b0c047477 100644
--- a/src/backend/commands/repack.c
+++ b/src/backend/commands/repack.c
@@ -3010,8 +3010,8 @@ initialize_change_context(ChangeContext *chgcxt,
/* Only initialize fields needed by ExecInsertIndexTuples(). */
chgcxt->cc_estate = CreateExecutorState();
- chgcxt->cc_rri = (ResultRelInfo *) palloc(sizeof(ResultRelInfo));
- InitResultRelInfo(chgcxt->cc_rri, relation, 0, 0, 0);
+ chgcxt->cc_rri = makeNode(ResultRelInfo);
+ InitResultRelInfo(chgcxt->cc_rri, relation, 0, NULL, 0);
ExecOpenIndices(chgcxt->cc_rri, false);
/*
--
2.52.0
--=-=-=
Content-Type: text/x-diff
Content-Disposition: attachment;
filename=0002-Provide-the-executor-with-information-on-updated-col.patch
^ permalink raw reply [nested|flat] 9+ messages in thread
* [PATCH 1/2] Minor cleanup in initialize_change_context().
@ 2026-07-01 12:58 Antonin Houska <[email protected]>
0 siblings, 0 replies; 9+ messages in thread
From: Antonin Houska @ 2026-07-01 12:58 UTC (permalink / raw)
First, use makeNode() to create an instance of ResultRelInfo, like we do
elsewhere in the tree.
Second, pass NULL for the 'partition_root_rri' argument of InitResultRelInfo
instead of 0.
---
src/backend/commands/repack.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/backend/commands/repack.c b/src/backend/commands/repack.c
index 4d177c868bb..c9b0c047477 100644
--- a/src/backend/commands/repack.c
+++ b/src/backend/commands/repack.c
@@ -3010,8 +3010,8 @@ initialize_change_context(ChangeContext *chgcxt,
/* Only initialize fields needed by ExecInsertIndexTuples(). */
chgcxt->cc_estate = CreateExecutorState();
- chgcxt->cc_rri = (ResultRelInfo *) palloc(sizeof(ResultRelInfo));
- InitResultRelInfo(chgcxt->cc_rri, relation, 0, 0, 0);
+ chgcxt->cc_rri = makeNode(ResultRelInfo);
+ InitResultRelInfo(chgcxt->cc_rri, relation, 0, NULL, 0);
ExecOpenIndices(chgcxt->cc_rri, false);
/*
--
2.52.0
--=-=-=
Content-Type: text/x-diff
Content-Disposition: attachment;
filename=0002-Provide-the-executor-with-information-on-updated-col.patch
^ permalink raw reply [nested|flat] 9+ messages in thread
* [PATCH 1/2] Minor cleanup in initialize_change_context().
@ 2026-07-01 12:58 Antonin Houska <[email protected]>
0 siblings, 0 replies; 9+ messages in thread
From: Antonin Houska @ 2026-07-01 12:58 UTC (permalink / raw)
First, use makeNode() to create an instance of ResultRelInfo, like we do
elsewhere in the tree.
Second, pass NULL for the 'partition_root_rri' argument of InitResultRelInfo
instead of 0.
---
src/backend/commands/repack.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/backend/commands/repack.c b/src/backend/commands/repack.c
index 4d177c868bb..c9b0c047477 100644
--- a/src/backend/commands/repack.c
+++ b/src/backend/commands/repack.c
@@ -3010,8 +3010,8 @@ initialize_change_context(ChangeContext *chgcxt,
/* Only initialize fields needed by ExecInsertIndexTuples(). */
chgcxt->cc_estate = CreateExecutorState();
- chgcxt->cc_rri = (ResultRelInfo *) palloc(sizeof(ResultRelInfo));
- InitResultRelInfo(chgcxt->cc_rri, relation, 0, 0, 0);
+ chgcxt->cc_rri = makeNode(ResultRelInfo);
+ InitResultRelInfo(chgcxt->cc_rri, relation, 0, NULL, 0);
ExecOpenIndices(chgcxt->cc_rri, false);
/*
--
2.52.0
--=-=-=
Content-Type: text/x-diff
Content-Disposition: attachment;
filename=0002-Provide-the-executor-with-information-on-updated-col.patch
^ permalink raw reply [nested|flat] 9+ messages in thread
* [PATCH 1/2] Minor cleanup in initialize_change_context().
@ 2026-07-01 12:58 Antonin Houska <[email protected]>
0 siblings, 0 replies; 9+ messages in thread
From: Antonin Houska @ 2026-07-01 12:58 UTC (permalink / raw)
First, use makeNode() to create an instance of ResultRelInfo, like we do
elsewhere in the tree.
Second, pass NULL for the 'partition_root_rri' argument of InitResultRelInfo
instead of 0.
---
src/backend/commands/repack.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/backend/commands/repack.c b/src/backend/commands/repack.c
index 4d177c868bb..c9b0c047477 100644
--- a/src/backend/commands/repack.c
+++ b/src/backend/commands/repack.c
@@ -3010,8 +3010,8 @@ initialize_change_context(ChangeContext *chgcxt,
/* Only initialize fields needed by ExecInsertIndexTuples(). */
chgcxt->cc_estate = CreateExecutorState();
- chgcxt->cc_rri = (ResultRelInfo *) palloc(sizeof(ResultRelInfo));
- InitResultRelInfo(chgcxt->cc_rri, relation, 0, 0, 0);
+ chgcxt->cc_rri = makeNode(ResultRelInfo);
+ InitResultRelInfo(chgcxt->cc_rri, relation, 0, NULL, 0);
ExecOpenIndices(chgcxt->cc_rri, false);
/*
--
2.52.0
--=-=-=
Content-Type: text/x-diff
Content-Disposition: attachment;
filename=0002-Provide-the-executor-with-information-on-updated-col.patch
^ permalink raw reply [nested|flat] 9+ messages in thread
* [PATCH 1/2] Minor cleanup in initialize_change_context().
@ 2026-07-01 12:58 Antonin Houska <[email protected]>
0 siblings, 0 replies; 9+ messages in thread
From: Antonin Houska @ 2026-07-01 12:58 UTC (permalink / raw)
First, use makeNode() to create an instance of ResultRelInfo, like we do
elsewhere in the tree.
Second, pass NULL for the 'partition_root_rri' argument of InitResultRelInfo
instead of 0.
---
src/backend/commands/repack.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/backend/commands/repack.c b/src/backend/commands/repack.c
index 4d177c868bb..c9b0c047477 100644
--- a/src/backend/commands/repack.c
+++ b/src/backend/commands/repack.c
@@ -3010,8 +3010,8 @@ initialize_change_context(ChangeContext *chgcxt,
/* Only initialize fields needed by ExecInsertIndexTuples(). */
chgcxt->cc_estate = CreateExecutorState();
- chgcxt->cc_rri = (ResultRelInfo *) palloc(sizeof(ResultRelInfo));
- InitResultRelInfo(chgcxt->cc_rri, relation, 0, 0, 0);
+ chgcxt->cc_rri = makeNode(ResultRelInfo);
+ InitResultRelInfo(chgcxt->cc_rri, relation, 0, NULL, 0);
ExecOpenIndices(chgcxt->cc_rri, false);
/*
--
2.52.0
--=-=-=
Content-Type: text/x-diff
Content-Disposition: attachment;
filename=0002-Provide-the-executor-with-information-on-updated-col.patch
^ permalink raw reply [nested|flat] 9+ messages in thread
* [PATCH 1/2] Minor cleanup in initialize_change_context().
@ 2026-07-01 12:58 Antonin Houska <[email protected]>
0 siblings, 0 replies; 9+ messages in thread
From: Antonin Houska @ 2026-07-01 12:58 UTC (permalink / raw)
First, use makeNode() to create an instance of ResultRelInfo, like we do
elsewhere in the tree.
Second, pass NULL for the 'partition_root_rri' argument of InitResultRelInfo
instead of 0.
---
src/backend/commands/repack.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/backend/commands/repack.c b/src/backend/commands/repack.c
index 4d177c868bb..c9b0c047477 100644
--- a/src/backend/commands/repack.c
+++ b/src/backend/commands/repack.c
@@ -3010,8 +3010,8 @@ initialize_change_context(ChangeContext *chgcxt,
/* Only initialize fields needed by ExecInsertIndexTuples(). */
chgcxt->cc_estate = CreateExecutorState();
- chgcxt->cc_rri = (ResultRelInfo *) palloc(sizeof(ResultRelInfo));
- InitResultRelInfo(chgcxt->cc_rri, relation, 0, 0, 0);
+ chgcxt->cc_rri = makeNode(ResultRelInfo);
+ InitResultRelInfo(chgcxt->cc_rri, relation, 0, NULL, 0);
ExecOpenIndices(chgcxt->cc_rri, false);
/*
--
2.52.0
--=-=-=
Content-Type: text/x-diff
Content-Disposition: attachment;
filename=0002-Provide-the-executor-with-information-on-updated-col.patch
^ permalink raw reply [nested|flat] 9+ messages in thread
* [PATCH 1/2] Minor cleanup in initialize_change_context().
@ 2026-07-01 12:58 Antonin Houska <[email protected]>
0 siblings, 0 replies; 9+ messages in thread
From: Antonin Houska @ 2026-07-01 12:58 UTC (permalink / raw)
First, use makeNode() to create an instance of ResultRelInfo, like we do
elsewhere in the tree.
Second, pass NULL for the 'partition_root_rri' argument of InitResultRelInfo
instead of 0.
---
src/backend/commands/repack.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/backend/commands/repack.c b/src/backend/commands/repack.c
index 4d177c868bb..c9b0c047477 100644
--- a/src/backend/commands/repack.c
+++ b/src/backend/commands/repack.c
@@ -3010,8 +3010,8 @@ initialize_change_context(ChangeContext *chgcxt,
/* Only initialize fields needed by ExecInsertIndexTuples(). */
chgcxt->cc_estate = CreateExecutorState();
- chgcxt->cc_rri = (ResultRelInfo *) palloc(sizeof(ResultRelInfo));
- InitResultRelInfo(chgcxt->cc_rri, relation, 0, 0, 0);
+ chgcxt->cc_rri = makeNode(ResultRelInfo);
+ InitResultRelInfo(chgcxt->cc_rri, relation, 0, NULL, 0);
ExecOpenIndices(chgcxt->cc_rri, false);
/*
--
2.52.0
--=-=-=
Content-Type: text/x-diff
Content-Disposition: attachment;
filename=0002-Provide-the-executor-with-information-on-updated-col.patch
^ permalink raw reply [nested|flat] 9+ messages in thread
* [PATCH 1/2] Minor cleanup in initialize_change_context().
@ 2026-07-01 12:58 Antonin Houska <[email protected]>
0 siblings, 0 replies; 9+ messages in thread
From: Antonin Houska @ 2026-07-01 12:58 UTC (permalink / raw)
First, use makeNode() to create an instance of ResultRelInfo, like we do
elsewhere in the tree.
Second, pass NULL for the 'partition_root_rri' argument of InitResultRelInfo
instead of 0.
---
src/backend/commands/repack.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/backend/commands/repack.c b/src/backend/commands/repack.c
index 4d177c868bb..c9b0c047477 100644
--- a/src/backend/commands/repack.c
+++ b/src/backend/commands/repack.c
@@ -3010,8 +3010,8 @@ initialize_change_context(ChangeContext *chgcxt,
/* Only initialize fields needed by ExecInsertIndexTuples(). */
chgcxt->cc_estate = CreateExecutorState();
- chgcxt->cc_rri = (ResultRelInfo *) palloc(sizeof(ResultRelInfo));
- InitResultRelInfo(chgcxt->cc_rri, relation, 0, 0, 0);
+ chgcxt->cc_rri = makeNode(ResultRelInfo);
+ InitResultRelInfo(chgcxt->cc_rri, relation, 0, NULL, 0);
ExecOpenIndices(chgcxt->cc_rri, false);
/*
--
2.52.0
--=-=-=
Content-Type: text/x-diff
Content-Disposition: attachment;
filename=0002-Provide-the-executor-with-information-on-updated-col.patch
^ permalink raw reply [nested|flat] 9+ messages in thread
end of thread, other threads:[~2026-07-01 12:58 UTC | newest]
Thread overview: 9+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2026-02-04 09:57 Re: Retiring is_pushed_down Álvaro Herrera <[email protected]>
2026-07-01 12:58 [PATCH 1/2] Minor cleanup in initialize_change_context(). Antonin Houska <[email protected]>
2026-07-01 12:58 [PATCH 1/2] Minor cleanup in initialize_change_context(). Antonin Houska <[email protected]>
2026-07-01 12:58 [PATCH 1/2] Minor cleanup in initialize_change_context(). Antonin Houska <[email protected]>
2026-07-01 12:58 [PATCH 1/2] Minor cleanup in initialize_change_context(). Antonin Houska <[email protected]>
2026-07-01 12:58 [PATCH 1/2] Minor cleanup in initialize_change_context(). Antonin Houska <[email protected]>
2026-07-01 12:58 [PATCH 1/2] Minor cleanup in initialize_change_context(). Antonin Houska <[email protected]>
2026-07-01 12:58 [PATCH 1/2] Minor cleanup in initialize_change_context(). Antonin Houska <[email protected]>
2026-07-01 12:58 [PATCH 1/2] Minor cleanup in initialize_change_context(). Antonin Houska <[email protected]>
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox