postgresql/contrib/postgres_fdw
Robert Haas 1bc0100d27 postgres_fdw: Push down UPDATE/DELETE joins to remote servers.
Commit 0bf3ae88af allowed direct
foreign table modification; instead of fetching each row, updating
it locally, and then pushing the modification back to the remote
side, we would instead do all the work on the remote server via a
single remote UPDATE or DELETE command.  However, that commit only
enabled this optimization when join tree consisted only of the
target table.

This change allows the same optimization when an UPDATE statement
has a FROM clause or a DELETE statement has a USING clause.  This
works much like ordinary foreign join pushdown, in that the tables
must be on the same remote server, relevant parts of the query
must be pushdown-safe, and so forth.

Etsuro Fujita, reviewed by Ashutosh Bapat, Rushabh Lathia, and me.
Some formatting corrections by me.

Discussion: http://postgr.es/m/5A57193A.2080003@lab.ntt.co.jp
Discussion: http://postgr.es/m/b9cee735-62f8-6c07-7528-6364ce9347d0@lab.ntt.co.jp
2018-02-07 15:34:30 -05:00
..
expected postgres_fdw: Push down UPDATE/DELETE joins to remote servers. 2018-02-07 15:34:30 -05:00
sql postgres_fdw: Push down UPDATE/DELETE joins to remote servers. 2018-02-07 15:34:30 -05:00
.gitignore Add postgres_fdw contrib module. 2013-02-21 05:27:16 -05:00
connection.c Update copyright for 2018 2018-01-02 23:30:12 -05:00
deparse.c postgres_fdw: Push down UPDATE/DELETE joins to remote servers. 2018-02-07 15:34:30 -05:00
Makefile Allow postgres_fdw to ship extension funcs/operators for remote execution. 2015-11-03 18:42:18 -05:00
option.c Update copyright for 2018 2018-01-02 23:30:12 -05:00
postgres_fdw--1.0.sql Add postgres_fdw contrib module. 2013-02-21 05:27:16 -05:00
postgres_fdw.c postgres_fdw: Push down UPDATE/DELETE joins to remote servers. 2018-02-07 15:34:30 -05:00
postgres_fdw.control Add postgres_fdw contrib module. 2013-02-21 05:27:16 -05:00
postgres_fdw.h postgres_fdw: Push down UPDATE/DELETE joins to remote servers. 2018-02-07 15:34:30 -05:00
shippable.c Update copyright for 2018 2018-01-02 23:30:12 -05:00