From: | Corey Huinker <corey(dot)huinker(at)gmail(dot)com> |
---|---|
To: | Álvaro Herrera <alvherre(at)kurilemu(dot)de> |
Cc: | Jeff Davis <pgsql(at)j-davis(dot)com>, Fujii Masao <masao(dot)fujii(at)oss(dot)nttdata(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, Nathan Bossart <nathandbossart(at)gmail(dot)com>, Peter Eisentraut <peter(at)eisentraut(dot)org>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: pg_dump --with-* options |
Date: | 2025-07-31 20:28:08 |
Message-ID: | CADkLM=fw9cbnjTAg8YoS_Rzo8Ohy4TgVzevSZ8g2WoF2Nx0JJQ@mail.gmail.com |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
>
>
> > I assume that should be read as something like "include only", because
> > --include=data would also be excluding the schema and the stats.
>
> Of course.
>
In general, I like the idea of --include, but it would need to be
consistent in behavior across pg_dump/pg_restore/pg_upgrade(if applicable).
Under the current defaults, if a person wanted a dump to include stats on
pg_dump they would need "--include=data,schema,statistics" (checking first
whether it was "statistics" or "stats"), but they could use the defaults on
pg_restore. Using the defaults on both would allow for stats to be
restored, but none would have been generated. That is confusing to me, and
I imagine it will be even more confusing to somebody who hasn't been
reading this thread.
I don't see anything wrong with a full complement of --something-only,
--no-something flags. The combinatorics aren't that hard, only tedious. If
we *must* make the defaults for pg_dump different from pg_restore and
pg_upgrade, then adding the --with-something flags becomes necessary, and
we let redundant non-conflicting combinations slide.
All of these problems are solved if we include statistics by default across
all three programs. Anything else involves complicated explanations that
will confuse the users who read them, and surprise the users who don't.
From | Date | Subject | |
---|---|---|---|
Next Message | Greg Sabino Mullane | 2025-07-31 20:42:26 | Re: Enable data checksums by default |
Previous Message | Laurenz Albe | 2025-07-31 19:28:18 | Re: Enable data checksums by default |