Re: Memoize ANTI and SEMI JOIN inner

From: Richard Guo <guofenglinux(at)gmail(dot)com>
To: Andrei Lepikhov <lepihov(at)gmail(dot)com>
Cc: David Rowley <dgrowleyml(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Memoize ANTI and SEMI JOIN inner
Date: 2025-04-01 07:18:58
Message-ID: CAMbWs49F9oR30P3AfQor_i-xLBEVuUOJvTxvzpy_wf-11PUYCw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Mar 31, 2025 at 7:33 PM Andrei Lepikhov <lepihov(at)gmail(dot)com> wrote:
> and I don't get the case. As I see, ANTI/SEMI join just transforms to
> the regular join and it is still not the case. May you be more specific?

Upthread, you said that a qual contained in ppi_clauses will also be
included in extra->restrictlist. I provided this example to show that
this is not true. And it seems to me that this discrepancy makes the
check I mentioned earlier not reliable in all cases. As I explained
earlier, this 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. This is not correct.

This isn't about your patch, but about the master code. However, if
this code is incorrect, your patch will also behave incorrectly, since
you patch relies on and extends this check.

Thanks
Richard

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Ashutosh Bapat 2025-04-01 07:24:13 statistics import and export: another difference in dump/restore
Previous Message Richard Guo 2025-04-01 06:34:22 Re: Reduce "Var IS [NOT] NULL" quals during constant folding