Re: [Proposal] Allow pg_dump to include all child tables with the root table

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Gilles Darold <gilles(at)migops(dot)com>
Cc: pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: [Proposal] Allow pg_dump to include all child tables with the root table
Date: 2023-03-04 19:18:13
Message-ID: 2984786.1677957493@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Gilles Darold <gilles(at)migops(dot)com> writes:
> But I disagree the use of --table-with-childs and
> --exclude-table-with-childs because we already have the --table and
> --exclude-table, and it will add lot of code where we just need a switch
> to include children tables.

I quite dislike the idea of a separate --with-whatever switch, because
it will (presumably) apply to all of your --table and --exclude-table
switches, where you may need it to apply to just some of them.
Spelling considerations aside, attaching the property to the
individual switches seems far superior. And I neither believe that
this would add a lot of code, nor accept that as an excuse even if
it's true.

As noted, "childs" is bad English and "partitions" is flat out wrong
(unless you change it to recurse only to partitions, which doesn't
seem like a better definition). We could go with
--[exclude-]table-and-children, or maybe
--[exclude-]table-and-child-tables, but those are getting into
carpal-tunnel-syndrome-inducing territory :-(. I lack a better
naming suggestion offhand.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Thomas Munro 2023-03-04 19:27:03 Re: Add standard collation UNICODE
Previous Message Tom Lane 2023-03-04 18:56:30 Re: Date-time extraneous fields with reserved keywords