| From: | Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com> |
|---|---|
| To: | Noah Misch <noah(at)leadboat(dot)com> |
| Cc: | Ajin Cherian <itsajin(at)gmail(dot)com>, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, PostgreSQL mailing lists <pgsql-hackers(at)postgresql(dot)org> |
| Subject: | Re: Add support for COPY TO in tablesync for partitioned tables. |
| Date: | 2026-09-08 17:40:09 |
| Message-ID: | CAD21AoCHOsE7C4+xEZT1uAHHiDwsjFNJ6i7hO5DwHT+LrC6_0Q@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Fri, Sep 4, 2026 at 9:00 PM Noah Misch <noah(at)leadboat(dot)com> wrote:
>
> On Thu, Nov 20, 2025 at 03:09:36PM -0800, Masahiko Sawada wrote:
> > Pushed.
>
> This became commit 266543a. It doesn't account for the publisher version, so
> replicating v18->v19 w/ publish_via_partition_root fails at tablesync w/
> "ERROR: cannot copy from partitioned table".
Good catch. I've attached the patch to fix it.
> I think commit 266543a also changes the behavior w/ foreign table partitions.
> A v19 subscriber will fail w/ "cannot copy from foreign table", whereas an
> older subscriber would have completed tablesync but handled no further foreign
> table changes. This consequence of 266543a is a net good, since the v18
> subscriber behavior is mostly a bug. Let's keep it. If someone really needs
> the v18 subscriber behavior, adding a no-op row filter achieves that.
Agreed.
Regards,
--
Masahiko Sawada
Amazon Web Services: https://aws.amazon.com
| Attachment | Content-Type | Size |
|---|---|---|
| v1-0001-Fix-tablesync-failure-for-partitioned-tables-on-o.patch | text/x-patch | 2.7 KB |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Noah Misch | 2026-09-08 17:47:07 | Re: Add support for COPY TO in tablesync for partitioned tables. |
| Previous Message | Greg Burd | 2026-09-08 17:28:22 | ExecForceStoreHeapTuple() loses tts_tid, so ORDER BY-op index scans project an invalid ctid |