RE: proposal: pg_restore --convert-to-text

Поиск
Список
Период
Сортировка
От Daniel Verite
Тема RE: proposal: pg_restore --convert-to-text
Дата
Msg-id 4c5d3ac3-36bc-45b2-85cc-c8e0b1404023@manitou-mail.org
обсуждение исходный текст
Ответ на RE: proposal: pg_restore --convert-to-text  ("José Arthur Benetasso Villanova" <jose.arthur@gmail.com>)
Ответы Re: proposal: pg_restore --convert-to-text  (Andrew Gierth <andrew@tao11.riddles.org.uk>)
Re: proposal: pg_restore --convert-to-text  (Alvaro Herrera <alvherre@2ndquadrant.com>)
Список pgsql-hackers
    José Arthur Benetasso Villanova wrote:

> On Thu, 28 Feb 2019, Imai, Yoshikazu wrote:
>
> > Is there no need to rewrite the Description in the Doc to state we should specify either -d or -f option?
> > (and also it might be better to write if -l option is given, neither -d nor -f option isn't necessarily needed.)
>
> Since the default part of text was removed, looks ok to me.

[4 months later]

While testing pg_restore on v12, I'm stumbling on this too.
pg_restore without argument fails like that:

$ pg_restore
pg_restore: error: one of -d/--dbname and -f/--file must be specified

But that's not right since "pg_restore -l dumpfile" would work.
I don't understand why the discussion seems to conclude that it's okay.

Also, in the doc at https://www.postgresql.org/docs/devel/app-pgrestore.html
the synopsis is

  pg_restore [connection-option...] [option...] [filename]

so the invocation without argument seems possible while in fact
it's not.

On a subjective note, I must say that I don't find the change to be
helpful.
In particular saying that --file must be specified leaves me with
no idea what file it's talking about: the dumpfile or the output file?
My first inclination is to transform "pg_restore dumpfile" into
"pg_restore -f dumpfile", which does nothing but wait
(it waits for the dumpfile on the standard input, before
I realize that it's not working and hit ^C. Fortunately it doesn't
overwrite the dumpfile with an empty output).

So the change in v12 removes the standard output as default,
but does not remove the standard input as default.
Isn't that weird?


Best regards,
--
Daniel Vérité
PostgreSQL-powered mailer: http://www.manitou-mail.org
Twitter: @DanielVerite



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Andrey Borodin
Дата:
Сообщение: Re: GiST limits on contrib/cube with dimension > 100?
Следующее
От: Siarhei Siniak
Дата:
Сообщение: Re: GiST limits on contrib/cube with dimension > 100?