From: | David Rowley <dgrowleyml(at)gmail(dot)com> |
---|---|
To: | Richard Guo <guofenglinux(at)gmail(dot)com> |
Cc: | Andrei Lepikhov <lepihov(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Memoize ANTI and SEMI JOIN inner |
Date: | 2025-03-31 09:39:14 |
Message-ID: | CAApHDvp0GagPFiu2ZDoWeZu+UaPpDwzsFTcT-gvp3=X7f002zw@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Mon, 31 Mar 2025 at 22:03, Richard Guo <guofenglinux(at)gmail(dot)com> wrote:
> I reviewed this patch and I have some concerns about the following
> code:
>
> if (extra->inner_unique &&
> (inner_path->param_info == NULL ||
> bms_num_members(inner_path->param_info->ppi_serials) <
> list_length(extra->restrictlist)))
> return NULL;
>
> I understand that this check is used to ensure that the entire join
> condition is parameterized in the case of unique joins, so that we can
> safely mark the cache entry as complete after reading the first tuple.
> However, ppi_clauses includes join clauses available from all outer
> rels, not just the current outer rel, while extra->restrictlist only
> includes the restriction clauses for the current join. This means the
> check could pass even if a restriction clause isn't parameterized, as
> long as another join clause, which doesn't belong to the current join,
> is included in ppi_clauses.
Shouldn't you be more concerned about master here than the patch given
that the code you pasted is from master?
David
From | Date | Subject | |
---|---|---|---|
Next Message | Andrei Lepikhov | 2025-03-31 09:46:08 | Re: Memoize ANTI and SEMI JOIN inner |
Previous Message | Mahendra Singh Thalor | 2025-03-31 09:34:38 | Re: Non-text mode for pg_dumpall |