Re: why -Fdance archive format option works with ./pg_restore but not with ./pg_dump?

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Srinath Reddy <srinath2133@gmail.com>
Cc: Andrew Dunstan <andrew@dunslane.net>, pgsql-hackers@lists.postgresql.org
Date: 2025-01-25T16:25:01Z
Lists: pgsql-hackers
Srinath Reddy <srinath2133@gmail.com> writes:
> wouldn't it be nice if we get the error message as same as when we didn't
> gave format option and pg_restore finds the format
> using _discoverArchiveFormat there it suggests to try psql ,instead of
> saying "p/plain text" format is a invalid format,as we are doing currently
> in pg.

Good idea.  I pushed your patch with that addition.

			regards, tom lane



Commits

  1. Tighten pg_restore's recognition of its -F (format) option values.