From: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
To: Alvaro Herrera <alvherre@alvh.no-ip.org>
Cc: Pg Hackers <pgsql-hackers@postgresql.org>
Subject: Re: Foreign keys and partitioned tables
Date: Mon, 2 Apr 2018 08:35:29 -0400
Message-ID: <bcf555a4-3a2c-2f40-8a3e-54e6b0a9b1a4@2ndquadrant.com> (raw)
In-Reply-To: <20180331222109.dwqlafrryaxo2clo@alvherre.pgsql>
References: <20180331222109.dwqlafrryaxo2clo@alvherre.pgsql>
On 3/31/18 18:21, Alvaro Herrera wrote:
> Yeah, I started by putting what I thought was going to be just ALTER
> TABLE in that test, then moved to the other file and added what I
> thought were more complete tests there and failed to move stuff to
> alter_table. Honestly, I think these should mostly all belong in
> foreign_key,
right
> <para>
> - Partitioned tables do not support <literal>EXCLUDE</literal> or
> - <literal>FOREIGN KEY</literal> constraints; however, you can define
> - these constraints on individual partitions.
> + Partitioned tables do not support <literal>EXCLUDE</literal> constraints;
> + however, you can define these constraints on individual partitions.
> + Also, while it's possible to define <literal>PRIMARY KEY</literal>
> + constraints on partitioned tables, it is not supported to create foreign
> + keys cannot that reference them. This restriction will be lifted in a
This doesn't read correctly.
> + future release.
> </para>
> - tables and permanent tables.
> + tables and permanent tables. Also note that while it is permitted to
> + define a foreign key on a partitioned table, declaring a foreign key
> + that references a partitioned table is not allowed.
> <para>
Maybe use "possible" or "supported" instead of "allowed" and "permitted"
in this and similar cases.
--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: peter.eisentraut@2ndquadrant.com, alvherre@alvh.no-ip.org
Subject: Re: Foreign keys and partitioned tables
In-Reply-To: <bcf555a4-3a2c-2f40-8a3e-54e6b0a9b1a4@2ndquadrant.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox