Re: Correction of RowMark Removal During Sel-Join Elimination - Mailing list pgsql-hackers

From Alexander Korotkov
Subject Re: Correction of RowMark Removal During Sel-Join Elimination
Date
Msg-id CAPpHfdsP_abX5hjnxiRJ6guU9P1FH4EdNTMksoGD05tTG1o9vA@mail.gmail.com
Whole thread Raw
In response to Re: Correction of RowMark Removal During Sel-Join Elimination  (Andrei Lepikhov <lepihov@gmail.com>)
List pgsql-hackers
Hi, Andrei!

On Tue, Aug 12, 2025 at 12:40 PM Andrei Lepikhov <lepihov@gmail.com> wrote:
> On 11/8/2025 20:15, Greg Sabino Mullane wrote:
> > I'm not convinced this is an improvement from someone just coming in to
> > this part of the code, especially given (for example) the comment right
> > above it:
> >
> >   * Determine if the inner table can duplicate outer rows.  We must
> >   * bypass the unique rel cache here since we're possibly using aThanks for your feedback.
> I made some minor adjustments to the comments to make the code more
> consistent. Sure, rrel and krel don't seem like the best solution - I
> guess natives could find less wordy synonyms than just dumb
> 'keeping_rel' and 'removing_rel'. But it is simpler to track which
> relation and RowMark should be removed.

Thank you for catching this.  And thank you for the fix.  I think it
worth separating fix and refactoring.  This helps to understand what
exactly the fix is by looking at the patch.  I also edited commit
message.  I'm going to push this if no objections.

------
Regards,
Alexander Korotkov
Supabase

Attachment

pgsql-hackers by date:

Previous
From: Noah Misch
Date:
Subject: Re: Test instability when pg_dump orders by OID
Next
From: Noah Misch
Date:
Subject: Re: Non-text mode for pg_dumpall