BUG #6751: usage flaws in pg_restore - Mailing list pgsql-bugs

From pilum.70@uni-muenster.de
Subject BUG #6751: usage flaws in pg_restore
Date
Msg-id E1SteUu-0002ER-Nm@wrigleys.postgresql.org
Whole thread Raw
Responses Re: BUG #6751: usage flaws in pg_restore  (Craig Ringer <ringerc@ringerc.id.au>)
Re: BUG #6751: usage flaws in pg_restore  (Marti Raudsepp <marti@juffo.org>)
List pgsql-bugs
The following bug has been logged on the website:

Bug reference:      6751
Logged by:          Arne Scheffer
Email address:      pilum.70@uni-muenster.de
PostgreSQL version: 9.1.4
Operating system:   Unix (RHEL 6)
Description:=20=20=20=20=20=20=20=20

We've been using PostgreSQL for years now.
It's great.
Only the usage of pg_restore is annoying
(Version 8.3 to 9.1 tested).

Please fix the following issues:
a.)
pg_dump -f sdfsdf.dump sdfsdf
pg_restore -d sdfsdf sdfsdf.dump
Given Answer:
 pg_restore: [archiver] input file does not appear to be a valid archive

(The User ist shocked. Dump possibly corrupted may be considered.)

Better:
 pg_restore: no archive, plain SQL-File detected, use psql -f instead (or \i
from console)

b.)
pg_restore --create -d sdfsdf sdfsdf.dump  (Dump also correctly using sdfsdf
as name in the SQL commands as documented)

Given answer: Database 'sdfsdf' does not exist.

(The User is confused, because therefore --create was used.)

Better: Simply make the intended happen.
Workaround: Tell the user in the answer how to use template0 as intended.

Many newcomers to PostgreSQL will appreciate that fix (and we could shorten
our introductions ;-)).

At least these issues should be mentioned in the documentation.

Thank you in advance

Arne Scheffer

Abteilung 3
ZIV
Muenster University

pgsql-bugs by date:

Previous
From: Jeff Davis
Date:
Subject: event triggers patch breaks with -DCLOBBER_CACHE_ALWAYS
Next
From: jez.wain@bull.net
Date:
Subject: BUG #6759: configure script fails to detect xlc compiler version