From: Álvaro Herrera <alvherre@kurilemu.de>
To: Jeff Davis <pgsql@j-davis.com>
Cc: Nathan Bossart <nathandbossart@gmail.com>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Peter Eisentraut <peter@eisentraut.org>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: pg_dump --with-* options
Date: Tue, 29 Jul 2025 20:22:24 +0200
Message-ID: <202507291822.z4sc4ddvg2kx@alvherre.pgsql> (raw)
In-Reply-To: <13a2cd63ec37d42b65bde5dadc39b61861e97cbc.camel@j-davis.com>
On 2025-Jul-29, Jeff Davis wrote:
> + /* reject conflicting "only-" and "with-" options */
> + if (data_only && with_schema)
> + pg_fatal("options -a/--data-only and --with-schema cannot be used together");
> + if (data_only && with_statistics)
> + pg_fatal("options -a/--data-only and --with-statistics cannot be used together");
> + if (schema_only && with_data)
> + pg_fatal("options -s/--schema-only and --with-data cannot be used together");
> + if (schema_only && with_statistics)
> + pg_fatal("options -s/--schema-only and --with-statistics cannot be used together");
> + if (statistics_only && with_data)
> + pg_fatal("options --statistics-only and --with-data cannot be used together");
> + if (statistics_only && with_schema)
> + pg_fatal("options --statistics-only and --with-schema cannot be used together");
Please move the switches themselves out of the translatable message,
otherwise there are too many of them. For instance,
pg_fatal("options %s and %s cannot be used together",
"-s/--schema-only", "--with-statistics");
Thanks
--
Álvaro Herrera 48°01'N 7°57'E — https://www.EnterpriseDB.com/
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 using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: alvherre@kurilemu.de, pgsql@j-davis.com, nathandbossart@gmail.com, robertmhaas@gmail.com, peter@eisentraut.org
Subject: Re: pg_dump --with-* options
In-Reply-To: <202507291822.z4sc4ddvg2kx@alvherre.pgsql>
* 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