Re: Support EXCEPT for TABLES IN SCHEMA publications - Mailing list pgsql-hackers

From Nisha Moond
Subject Re: Support EXCEPT for TABLES IN SCHEMA publications
Date
Msg-id CABdArM7iswxPXwXFuNNX4PGMk8vQTLjsAL+YewZtkJ-D7Q+Rug@mail.gmail.com
Whole thread
In response to Support EXCEPT for TABLES IN SCHEMA publications  (Nisha Moond <nisha.moond412@gmail.com>)
List pgsql-hackers
On Tue, Jul 28, 2026 at 2:38 PM shveta malik <shveta.malik@gmail.com> wrote:
>
> Nisha, the changes in RelationBuildPublicationDesc() looks quite
> tricky now. We are doing 'list_difference_oid' thrice:
>
> --for schema-pub
> --for schmea-pubs on complete ancestor tree
> --for all-tables pub
>
> Ultimately we are concatenating all individual pubids after
> subtracting 'exceptpuboids' from each individual 'puboids' list. The
> 'exceptpuboids' is computed only once and doesn't change with each
> computation. Why don't we uncondiitonally do list_concat_unique_oid
> for all pub-ids
> and only minus 'exceptpuboids' once at the end? Won't it work? Let me
> know if I am missing something.
>

Done as suggested. The change modifies the existing code slightly, but
the function now seems simpler and easier to read overall. It works
well based on my testing. I'll do a deeper analysis to ensure it
doesn't change any existing behavior.

> ~~
>
> I think, we can now merge 002 to 001, it will help in combined review
> by placing except-validation logic where it should ultimately be.
>

Merged both into v24-0001.
~~~

Attached v24 patch set.

--
Thanks,
Nisha

Attachment

pgsql-hackers by date:

Previous
From: Rafia Sabih
Date:
Subject: Re: Fix BUG #19586: money division overflow for INT64_MIN / -1
Next
From: Nisha Moond
Date:
Subject: Re: Support EXCEPT for TABLES IN SCHEMA publications