Re: 9.5 release notes may need ON CONFLICT DO NOTHING compatibility notice for FDW authors

Поиск
Список
Период
Сортировка
От Simon Riggs
Тема Re: 9.5 release notes may need ON CONFLICT DO NOTHING compatibility notice for FDW authors
Дата
Msg-id CANP8+jJpoiHKOwh7p3p6LD0_aea6MbKvuXNSXcJOmoincdw7Lg@mail.gmail.com
обсуждение исходный текст
Ответ на 9.5 release notes may need ON CONFLICT DO NOTHING compatibility notice for FDW authors  (Peter Geoghegan <pg@heroku.com>)
Ответы Re: 9.5 release notes may need ON CONFLICT DO NOTHING compatibility notice for FDW authors  (Peter Geoghegan <pg@heroku.com>)
Список pgsql-hackers
On 25 May 2015 at 00:22, Peter Geoghegan <pg@heroku.com> wrote:

There is no support for ON CONFLICT DO UPDATE with postgres_fdw, but
that's really only because an inference specification (or explicitly
named constraint) is always required for DO UPDATE. The deparsing
support actually added will have deparsing add "ON CONFLICT DO
NOTHING" for the SQL generated for execution on foreign servers if the
original statement had that exact, unadorned ON CONFLICT clause. As
things stand, every other possible ON CONFLICT clause will throw an
error in some way before the FDW is consulted at all, so FDW authors
need not concern themselves with those other cases (unless perhaps we
allow ON CONFLICT DO UPDATE to not require an inference specification
in a last minute behavioral tweak, as suggested by Simon Riggs, making
ON CONFLICT DO UPDATE support by foreign data wrappers a possibility
that must be considered).

My earlier summary was that the support for multiple constraints has been poorly thought through. This is an example of the breakage I have been complaining about when we are forced to specify the constraint (conflict-target).

This is not just related to FDWs and should not be fixed solely for FDWs. This was already an open item for me in 9.5, now even more so.

My comments do not come at the last minute, what Peter means is that we should make a change now in response to the concerns I have previously raised.

--
Simon Riggs                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Stefan Kaltenbrunner
Дата:
Сообщение: Re: problems on Solaris
Следующее
От: Kouhei Kaigai
Дата:
Сообщение: Construction of Plan-node by CSP (RE: Custom/Foreign-Join-APIs)