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: Add support for --no-table-access-method in pg_{dump,dumpall,res
Date: Mon, 17 Jan 2022 05:52:02 +0000
Message-ID: <E1n9Kvy-00084r-Sz@gemulon.postgresql.org> (raw)

Add support for --no-table-access-method in pg_{dump,dumpall,restore}

The logic is similar to default_tablespace in some ways, so as no SET
queries on default_table_access_method are generated before dumping or
restoring an object (table or materialized view support table AMs) when
specifying this new option.

This option is useful to enforce the use of a default access method even
if some tables included in a dump use an AM different than the system's
default.

There are already two cases in the TAP tests of pg_dump with a table and
a materialized view that use a non-default table AM, and these are
extended that the new option does not generate SET clauses on
default_table_access_method.

Author: Justin Pryzby
Discussion: https://postgr.es/m/20211207153930.GR17618@telsasoft.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/2158628864cfbc03c838834a46c193bde5807361

Modified Files
--------------
doc/src/sgml/ref/pg_dump.sgml        | 17 +++++++++++++++++
doc/src/sgml/ref/pg_dumpall.sgml     | 11 +++++++++++
doc/src/sgml/ref/pg_restore.sgml     | 11 +++++++++++
src/bin/pg_dump/pg_backup.h          |  2 ++
src/bin/pg_dump/pg_backup_archiver.c | 12 ++++++++++++
src/bin/pg_dump/pg_dump.c            |  3 +++
src/bin/pg_dump/pg_dumpall.c         |  5 +++++
src/bin/pg_dump/pg_restore.c         |  4 ++++
src/bin/pg_dump/t/002_pg_dump.pl     | 16 ++++++++++++++--
9 files changed, 79 insertions(+), 2 deletions(-)



Message-ID: <E1n9Kvy-00084r-Sz@gemulon.postgresql.org>
Permalink:  ../E1n9Kvy-00084r-Sz@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1n9Kvy-00084r-Sz@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: Add support for --no-table-access-method in pg_{dump,dumpall,res
  In-Reply-To: <E1n9Kvy-00084r-Sz@gemulon.postgresql.org>
  References: <E1n9Kvy-00084r-Sz@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