Re: Reduce LEFT/FULL JOIN to ANTI JOIN in more cases

From: wenhui qiu <qiuwenhuifx(at)gmail(dot)com>
To: Richard Guo <guofenglinux(at)gmail(dot)com>
Cc: Isaac Morland <isaac(dot)morland(at)gmail(dot)com>, Pg Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Reduce LEFT/FULL JOIN to ANTI JOIN in more cases
Date: 2026-06-23 06:16:52
Message-ID: CAGjGUA+wc8jrRQ0kYRERaHJEX1zSPHq8O44ZAV06KippcsXKDw@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

HI Richard

> I considered that. It would give the same answer, but I think
> > carrying the raw quals is the better deal: pass2 runs
> > find_nonnullable_vars only when it actually has forced-null vars in
> > hand, so the common case of outer joins without any IS NULL quals pays
> > nothing, whereas deriving the set in pass1 would walk every collected
> > qual for every query containing an outer join.
> Thank you for your explanation,
>
> > 0001 and 0002 are as before.

0003,0004 LGTM, I will invite other Hackers to take a look.

Thanks

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Jakub Wartak 2026-06-23 06:35:51 Re: Allow pg_log_backend_memory_contexts() for postmaster
Previous Message Kyotaro Horiguchi 2026-06-23 06:15:57 Re: [PATCH] Add pg_get_table_ddl() to reconstruct CREATE TABLE statements