Re: foreign partition DDL regression tests
Robert Haas <robertmhaas@gmail.com>
From: Robert Haas <robertmhaas@gmail.com>
To: Ashutosh Bapat <ashutosh.bapat@enterprisedb.com>
Cc: Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>, Pg Hackers <pgsql-hackers@postgresql.org>
Date: 2017-03-08T15:04:26Z
Lists: pgsql-hackers
On Tue, Mar 7, 2017 at 11:18 PM, Ashutosh Bapat <ashutosh.bapat@enterprisedb.com> wrote: >> I agree that we could do that, but what value would it have? It just >> forces the user to spend two SQL commands doing what could otherwise >> be done in one. > > I don't think it's going to be two commands always. A user who wants > to attach a foreign table as a partition, "knows" that the data on the > foreign server honours the partitioning bounds. If s/he knows that > probably he added the constraint on the foreign table, so that planner > could make use of it. Remember this is an existing foreign table. If > s/he is not aware that the data on the foreign server doesn't honour > partition bounds, adding that as a partition would be a problem. I > think, this step gives the user a chance to make a conscious decision. I think attaching the foreign table as a partition constitutes a sufficiently-conscious decision. > At least we need to update the documentation. Got a proposal? -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company
Commits
-
Document lack of validation when attaching foreign partitions.
- b54aad8e34bd 10.0 landed
-
Add tests for foreign partitions.
- 0d130c7abc85 10.0 landed