| From: | Nisha Moond <nisha(dot)moond412(at)gmail(dot)com> |
|---|---|
| To: | Peter Smith <smithpb2250(at)gmail(dot)com> |
| Cc: | shveta malik <shveta(dot)malik(at)gmail(dot)com>, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
| Subject: | Re: Support EXCEPT for TABLES IN SCHEMA publications |
| Date: | 2026-05-04 12:05:39 |
| Message-ID: | CABdArM7ruJaa3js7o5C619YLESDhF1xfJOdmNnUE0PD30H31BA@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Wed, Apr 29, 2026 at 11:16 AM Peter Smith <smithpb2250(at)gmail(dot)com> wrote:
>
> Hi Nisha.
>
> Some review comments for v4-0001 (docs only).
>
Thank you Peter for the review.
> ======
> doc/src/sgml/ref/create_publication.sgml
>
> 1.
> + TABLES IN SCHEMA { <replaceable
> class="parameter">schema_name</replaceable> | CURRENT_SCHEMA } [
> EXCEPT ( <replaceable
> class="parameter">except_table_object</replaceable> [, ... ] ) ] [,
> ... ]
>
> It is ambiguous which part does that last ellipsis applies to?
>
> Consider instead:
>
> TABLES IN SCHEMA tables_in_schema [, ... ]
>
> and tables_in_schema is:
> { schema_name | CURRENT_SCHEMA } [ EXCEPT ( except_table_object [, ... ] ) ]
>
> ~~~
Fixed.
>
> 2.
> <para>
> This clause specifies a list of tables to be excluded from the
> - publication.
> + publication. It can be used with both <literal>FOR ALL TABLES</literal>
> + and <literal>FOR TABLES IN SCHEMA</literal>.
> </para>
>
> Saying "both" may imply they can coexist, but they cannot.
>
> SUGGESTION
> It can be used with <literal>FOR ALL TABLES</literal> or <literal>FOR
> TABLES IN SCHEMA</literal>.
>
> ~~~
Fixed.
>
> 3.
> + <para>
> + Create a publication that publishes all changes for all the tables
> present in
> + the schema <structname>sales</structname>, except
> + <structname>sales.internal</structname> and
> <structname>sales.drafts</structname>:
> +<programlisting>
> +CREATE PUBLICATION sales_filtered FOR TABLES IN SCHEMA sales EXCEPT
> (TABLE sales.internal, sales.drafts);
> +</programlisting>
> + </para>
> +
>
> AFAIK, the tables in the EXCEPT clause do not need to be
> schema-qualified, so they should not be written that way in the
> programlisting part of this example, because it might give the user
> the impression that schema-qualified names are required.
>
Done, matched with nearby examples.
All of the above comments are addressed in v5-0001 patch.
--
Thanks,
Nisha
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Nisha Moond | 2026-05-04 12:05:48 | Re: Support EXCEPT for TABLES IN SCHEMA publications |
| Previous Message | David Geier | 2026-05-04 11:53:48 | Re: Wrong results with equality search using trigram index and non-deterministic collation |