Re: Cannot dump foreign key constraints on partitioned table

From: Michael Paquier <michael(at)paquier(dot)xyz>
To: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
Cc: amul sul <sulamul(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Cannot dump foreign key constraints on partitioned table
Date: 2018-07-13 04:50:27
Message-ID: 20180713045027.GC23895@paquier.xyz
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Jul 12, 2018 at 11:34:43PM -0400, Alvaro Herrera wrote:
> I'm not sure what to *do* with the partition, though :-) I don't think
> there's a nice way to verify that the FK actually exists, or that
> catalog rows are set in such-and-such way, after restoring this.
> The pg_restore tests are marked TODO in the suite. I think that'll have
> to wait.

Ouch, right. My eyes are betraying me. I swear when I tested that I
saw an ALTER TABLE ADD CONSTRAINT command generated as well for each
partition on top of the parent :)

But only the parent needs to have the definition, so your test is
sufficient. Sorry for the noise.
--
Michael

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Thomas Munro 2018-07-13 05:09:29 Re: file cloning in pg_upgrade and CREATE DATABASE
Previous Message Thomas Munro 2018-07-13 04:44:19 Re: Checkpoint not retrying failed fsync?