Re: Cross-version Compatibility of postgres_fdw

From: Etsuro Fujita <etsuro(dot)fujita(at)gmail(dot)com>
To: Fujii Masao <masao(dot)fujii(at)oss(dot)nttdata(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Cross-version Compatibility of postgres_fdw
Date: 2024-08-09 08:49:41
Message-ID: CAPmGK15KcLai=7LORYHFKnO3=6n+KMX-TETj1B4U35mus9HqVQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Aug 7, 2024 at 9:32 PM Fujii Masao <masao(dot)fujii(at)oss(dot)nttdata(dot)com> wrote:
> However, when using PostgreSQL 9.4 or earlier as a remote server,
> INSERT ON CONFLICT on a foreign table fails because this feature
> is only supported in v9.5 and later. Should we add a note to
> the documentation to clarify this limitation?

+1

> For example:
> "Another limitation is that when executing INSERT statements with
> an ON CONFLICT DO NOTHING clause on a foreign table, the remote server
> must be running PostgreSQL 9.5 or later, as earlier versions do not
> support this feature."

We already have this note in the documentation:

“Note that postgres_fdw currently lacks support for INSERT statements
with an ON CONFLICT DO UPDATE clause. However, the ON CONFLICT DO
NOTHING clause is supported, provided a unique index inference
specification is omitted.”

So yet another idea is to expand the latter part a little bit like:

However, the ON CONFLICT DO NOTHING clause is supported, provided a
unique index inference specification is omitted and the remote server
is 9.5 or later.

I just thought consolidating the information to one place would make
the documentation more readable.

Best regards,
Etsuro Fujita

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Heikki Linnakangas 2024-08-09 08:59:12 Re: Improve error message for ICU libraries if pkg-config is absent
Previous Message Etsuro Fujita 2024-08-09 08:35:11 Re: Skip adding row-marks for non target tables when result relation is foreign table.