pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Michael Paquier <michael@paquier.xyz>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Avoid retrieval of CHECK constraints and DEFAULT exprs in data-o
Date: Wed, 16 Sep 2020 07:30:14 +0000
Message-ID: <E1kIRtO-0002TD-Bh@gemulon.postgresql.org> (raw)

Avoid retrieval of CHECK constraints and DEFAULT exprs in data-only dump

Those extra queries are not necessary when doing a data-only dump.  With
this change, this means that the dependencies between CHECK/DEFAULT and
the parent table are not tracked anymore for a data-only dump.  However,
these dependencies are only used for the schema generation and we have
never guaranteed that a dump can be reloaded if a CHECK constraint uses
a custom function whose behavior changes when loading the data, like
when using cross-table references in the CHECK function.

Author: Julien Rouhaud
Reviewed-by: Daniel Gustafsson, Michael Paquier
Discussion: https://postgr.es/m/20200712054850.GA92357@nol

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/5423853feebd30772b7ff9b306885dcb02b79e76

Modified Files
--------------
src/bin/pg_dump/pg_dump.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)



Message-ID: <E1kIRtO-0002TD-Bh@gemulon.postgresql.org>
Permalink:  ../E1kIRtO-0002TD-Bh@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1kIRtO-0002TD-Bh@gemulon.postgresql.org

 · 

reply

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: michael@paquier.xyz
  Subject: Re: pgsql: Avoid retrieval of CHECK constraints and DEFAULT exprs in data-o
  In-Reply-To: <E1kIRtO-0002TD-Bh@gemulon.postgresql.org>
  References: <E1kIRtO-0002TD-Bh@gemulon.postgresql.org>

* 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