Re: Key joins

From: Arne Roland <arne(dot)roland(at)malkut(dot)net>
To: Tomas Vondra <tomas(at)vondra(dot)me>, Joel Jacobson <joel(at)compiler(dot)org>, Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Cc: Anders Granlund <anders(dot)granlund(dot)0(at)gmail(dot)com>, Andreas Karlsson <andreas(at)proxel(dot)se>, Vik Fearing <vik(at)chouppes(dot)com>
Subject: Re: Key joins
Date: 2026-07-08 00:19:30
Message-ID: 5dfdf034-2735-45af-8320-de0c516e1a13@malkut.net
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

the attached patch set is my attempt to break it up in a granular way. I
will think about this further, but attached is my current patch, since
it seems much easier to read.

The difference to before is that the base commit is further broken up
into a series of it's own:

1. Only prove FOR KEY joins between two base tables
2. Mechanics for advanced error messages
3. Derived tables
4. GROUP BY and DISTINCT
5. FILTER (WHERE ...)
6. Tracking of referenced and referencing filter clauses

The later commits have only minor comment adjustments. The series should
be easier to read now, since the individual steps with very different
concerns are added one at a time. Please let me know, what you think.

Regards
Arne

On 2026-06-28 1:05 AM, Arne Roland wrote:
> Hello together,
>
> the main reason I'm re-positing is to fix a psql issue with the test
> tty layout, to keep CF bot happy. The code itself wasn't altered there.
>
> I also did some rewording in some comments and altered the way how to
> lock against concurrent inheritance schema changes in the 0003 patch.
>
> Regards
> Arne
>

Attachment Content-Type Size
v13-0010-Add-psql-tab-completion-for-FOR-KEY-joins.patch.gz application/gzip 11.5 KB
v13-0002-Add-error-details-to-FOR-KEY-join-rejections.patch.gz application/gzip 7.9 KB
v13-0004-Derive-key-join-proof-facts-from-GROUP-BY-and-DI.patch.gz application/gzip 17.0 KB
v13-0005-Add-a-join-local-FILTER-WHERE-.-clause.patch.gz application/gzip 7.0 KB
v13-0008-Record-and-revalidate-FOR-KEY-proof-dependencies.patch.gz application/gzip 79.1 KB
v13-0006-Prove-FOR-KEY-joins-whose-referenced-input-is-fi.patch.gz application/gzip 40.4 KB
v13-0009-Add-information_schema.view_constraint_usage.patch.gz application/gzip 2.9 KB
v13-0007-Serialize-concurrent-routine-definition-changes.patch.gz application/gzip 1.7 KB
v13-0003-Prove-FOR-KEY-joins-over-derived-inputs.patch.gz application/gzip 38.8 KB
v13-0001-Add-FOR-KEY-join-clause-and-parse-time-proof.patch.gz application/gzip 56.2 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Alexander Korotkov 2026-07-08 00:19:40 Re: wait_event_type for WAIT FOR LSN
Previous Message Alexander Korotkov 2026-07-08 00:18:18 Re: SPLIT/MERGE use of is_internal=true