postgresql/contrib
Tom Lane cb1ca4d800 Allow foreign tables to participate in inheritance.
Foreign tables can now be inheritance children, or parents.  Much of the
system was already ready for this, but we had to fix a few things of
course, mostly in the area of planner and executor handling of row locks.

As side effects of this, allow foreign tables to have NOT VALID CHECK
constraints (and hence to accept ALTER ... VALIDATE CONSTRAINT), and to
accept ALTER SET STORAGE and ALTER SET WITH/WITHOUT OIDS.  Continuing to
disallow these things would've required bizarre and inconsistent special
cases in inheritance behavior.  Since foreign tables don't enforce CHECK
constraints anyway, a NOT VALID one is a complete no-op, but that doesn't
mean we shouldn't allow it.  And it's possible that some FDWs might have
use for SET STORAGE or SET WITH OIDS, though doubtless they will be no-ops
for most.

An additional change in support of this is that when a ModifyTable node
has multiple target tables, they will all now be explicitly identified
in EXPLAIN output, for example:

 Update on pt1  (cost=0.00..321.05 rows=3541 width=46)
   Update on pt1
   Foreign Update on ft1
   Foreign Update on ft2
   Update on child3
   ->  Seq Scan on pt1  (cost=0.00..0.00 rows=1 width=46)
   ->  Foreign Scan on ft1  (cost=100.00..148.03 rows=1170 width=46)
   ->  Foreign Scan on ft2  (cost=100.00..148.03 rows=1170 width=46)
   ->  Seq Scan on child3  (cost=0.00..25.00 rows=1200 width=46)

This was done mainly to provide an unambiguous place to attach "Remote SQL"
fields, but it is useful for inherited updates even when no foreign tables
are involved.

Shigeru Hanada and Etsuro Fujita, reviewed by Ashutosh Bapat and Kyotaro
Horiguchi, some additional hacking by me
2015-03-22 13:53:21 -04:00
..
adminpack
auth_delay
auto_explain Rearrange explain.c's API so callers need not embed sizeof(ExplainState). 2015-01-15 13:39:33 -05:00
btree_gin
btree_gist Remove dead NULL-pointer checks in GiST code. 2015-01-28 10:03:58 +02:00
chkpass Avoid returning undefined bytes in chkpass_in(). 2015-02-14 12:20:56 -05:00
citext
cube Add macros wrapping all usage of gcc's __attribute__. 2015-03-11 14:30:01 +01:00
dblink Fix volatile-safety issue in dblink's materializeQueryResult(). 2015-01-26 15:17:33 -05:00
dict_int
dict_xsyn
earthdistance
file_fdw Allow foreign tables to participate in inheritance. 2015-03-22 13:53:21 -04:00
fuzzystrmatch Remove dead code. 2015-02-03 09:43:44 +02:00
hstore Use FLEXIBLE_ARRAY_MEMBER in a number of other places. 2015-02-21 16:12:14 -05:00
intagg
intarray Replace insertion sort in contrib/intarray with qsort(). 2015-03-15 23:22:03 -04:00
isn Replace a bunch more uses of strncpy() with safer coding. 2015-01-24 13:05:42 -05:00
lo
ltree Use FLEXIBLE_ARRAY_MEMBER in a bunch more places. 2015-02-20 00:11:42 -05:00
oid2name
pageinspect Move BRIN page type to page's last two bytes 2015-03-10 12:27:15 -03:00
passwordcheck
pg_archivecleanup
pg_buffercache Align buffer descriptors to cache line boundaries. 2015-01-29 22:48:45 +01:00
pg_freespacemap
pg_prewarm
pg_standby pg_standby: Avoid writing one byte beyond the end of the buffer. 2015-01-15 09:26:03 -05:00
pg_stat_statements Prevent duplicate escape-string warnings when using pg_stat_statements. 2015-01-22 18:11:00 -05:00
pg_test_fsync
pg_test_timing
pg_trgm Use FLEXIBLE_ARRAY_MEMBER in a bunch more places. 2015-02-20 00:11:42 -05:00
pg_upgrade Add macros wrapping all usage of gcc's __attribute__. 2015-03-11 14:30:01 +01:00
pg_upgrade_support
pg_xlogdump Add macros wrapping all usage of gcc's __attribute__. 2015-03-11 14:30:01 +01:00
pgbench pgbench: Fix mistakes in Makefile. 2015-03-03 10:48:16 -05:00
pgcrypto Add macros wrapping all usage of gcc's __attribute__. 2015-03-11 14:30:01 +01:00
pgrowlocks
pgstattuple
postgres_fdw Allow foreign tables to participate in inheritance. 2015-03-22 13:53:21 -04:00
seg Add macros wrapping all usage of gcc's __attribute__. 2015-03-11 14:30:01 +01:00
sepgsql sepgsql: Improve error message when unsupported object type is labeled. 2015-03-11 12:12:10 -04:00
spi Use FLEXIBLE_ARRAY_MEMBER in a number of other places. 2015-02-21 16:12:14 -05:00
sslinfo
start-scripts
tablefunc Handle unexpected query results, especially NULLs, safely in connectby(). 2015-01-29 20:18:33 -05:00
tcn
test_decoding
tsearch2
unaccent
uuid-ossp
vacuumlo
xml2 Replace a bunch more uses of strncpy() with safer coding. 2015-01-24 13:05:42 -05:00
contrib-global.mk
Makefile
README

The PostgreSQL contrib tree
---------------------------

This subtree contains porting tools, analysis utilities, and plug-in
features that are not part of the core PostgreSQL system, mainly
because they address a limited audience or are too experimental to be
part of the main source tree.  This does not preclude their
usefulness.

User documentation for each module appears in the main SGML
documentation.

When building from the source distribution, these modules are not
built automatically, unless you build the "world" target.  You can
also build and install them all by running "make all" and "make
install" in this directory; or to build and install just one selected
module, do the same in that module's subdirectory.

Some directories supply new user-defined functions, operators, or
types.  To make use of one of these modules, after you have installed
the code you need to register the new SQL objects in the database
system by executing a CREATE EXTENSION command.  In a fresh database,
you can simply do

    CREATE EXTENSION module_name;

See the PostgreSQL documentation for more information about this
procedure.