postgresql/src/backend
Alvaro Herrera eb7ed3f306 Allow UNIQUE indexes on partitioned tables
If we restrict unique constraints on partitioned tables so that they
must always include the partition key, then our standard approach to
unique indexes already works --- each unique key is forced to exist
within a single partition, so enforcing the unique restriction in each
index individually is enough to have it enforced globally.  Therefore we
can implement unique indexes on partitions by simply removing a few
restrictions (and adding others.)

Discussion: https://postgr.es/m/20171222212921.hi6hg6pem2w2t36z@alvherre.pgsql
Discussion: https://postgr.es/m/20171229230607.3iib6b62fn3uaf47@alvherre.pgsql
Reviewed-by: Simon Riggs, Jesper Pedersen, Peter Eisentraut, Jaime
	Casanova, Amit Langote
2018-02-19 17:40:00 -03:00
..
access Minor comment fix 2018-02-17 20:45:02 -05:00
bootstrap Allow UNIQUE indexes on partitioned tables 2018-02-19 17:40:00 -03:00
catalog Allow UNIQUE indexes on partitioned tables 2018-02-19 17:40:00 -03:00
commands Allow UNIQUE indexes on partitioned tables 2018-02-19 17:40:00 -03:00
executor Remove redundant initialization of a local variable. 2018-02-18 23:32:56 -05:00
foreign Remove bogus "extern" annotations on function definitions. 2018-02-19 12:07:44 -05:00
lib Remove some inappropriate #includes. 2018-02-16 12:14:08 -05:00
libpq Fix up references to scram-sha-256 2018-01-30 16:50:30 -05:00
main Update copyright for 2018 2018-01-02 23:30:12 -05:00
nodes Support all SQL:2011 options for window frame clauses. 2018-02-07 00:06:56 -05:00
optimizer Rename enable_partition_wise_join to enable_partitionwise_join 2018-02-16 10:33:59 -05:00
parser Allow UNIQUE indexes on partitioned tables 2018-02-19 17:40:00 -03:00
po Translation updates 2017-08-07 13:55:34 -04:00
port Support huge pages on Windows 2018-01-21 15:40:46 +01:00
postmaster Support parallel btree index builds. 2018-02-02 13:32:44 -05:00
regex Update copyright for 2018 2018-01-02 23:30:12 -05:00
replication Allow tupleslots to have a fixed tupledesc, use in executor nodes. 2018-02-16 21:17:38 -08:00
rewrite Fix application of identity values in some cases 2018-02-02 14:39:10 -05:00
snowball Avoid unnecessary use of pg_strcasecmp for already-downcased identifiers. 2018-01-26 18:25:14 -05:00
statistics Update copyright for 2018 2018-01-02 23:30:12 -05:00
storage Remove bogus "extern" annotations on function definitions. 2018-02-19 12:07:44 -05:00
tcop Allow UNIQUE indexes on partitioned tables 2018-02-19 17:40:00 -03:00
tsearch Avoid unnecessary use of pg_strcasecmp for already-downcased identifiers. 2018-01-26 18:25:14 -05:00
utils Remove bogus "extern" annotations on function definitions. 2018-02-19 12:07:44 -05:00
.gitignore Add .gitignore entries for AIX-specific intermediate build artifacts. 2015-07-08 20:44:22 -04:00
common.mk Add ICU_CFLAGS to global CPPFLAGS 2017-06-12 15:57:22 -04:00
Makefile Update copyright for 2018 2018-01-02 23:30:12 -05:00
nls.mk Translation updates 2017-05-15 12:19:54 -04:00