Re: [HACKERS] postgres_fdw: Add support for INSERT OVERRIDING clause
От | Michael Paquier |
---|---|
Тема | Re: [HACKERS] postgres_fdw: Add support for INSERT OVERRIDING clause |
Дата | |
Msg-id | CAB7nPqQv8Bd2EQdv9QaF1QSeP2Qbzsh2Ljp5N6O9ym9K1VU6RA@mail.gmail.com обсуждение исходный текст |
Ответ на | [HACKERS] postgres_fdw: Add support for INSERT OVERRIDING clause (Peter Eisentraut <peter.eisentraut@2ndquadrant.com>) |
Ответы |
Re: [HACKERS] postgres_fdw: Add support for INSERT OVERRIDING clause
|
Список | pgsql-hackers |
On Tue, Oct 31, 2017 at 3:45 PM, Peter Eisentraut <peter.eisentraut@2ndquadrant.com> wrote: > It has been pointed out to me that the command deparsing in postgres_fdw > does not support the INSERT OVERRIDING clause that was added in PG10. > Here is a patch that seems to fix that. I don't know much about this, > whether anything else needs to be added or whether there should be > tests. Perhaps someone more familiar with postgres_fdw details can > check it. Trying to insert some data using OVERRIDING SYSTEM VALUE on a foreign table with a remote relation defined with GENERATED ALWAYS would just fail: =# insert into id_always_foreign OVERRIDING system VALUE values (8); ERROR: 428C9: cannot insert into column "a" DETAIL: Column "a" is an identity column defined as GENERATED ALWAYS. HINT: Use OVERRIDING SYSTEM VALUE to override. And that's confusing because there is no actual way to avoid this error if postgres_fdw is unpatched. I think that you should add some tests, and make sure that the documentation of postgres-fdw.sgml mentions that those two clauses are pushed down. -- Michael -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
В списке pgsql-hackers по дате отправления: