Re: BUG #6007: pg_restore -C -d <database> does not behave as expected when dump is done with pg_dump

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "gab" <korsani(at)free(dot)fr>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #6007: pg_restore -C -d <database> does not behave as expected when dump is done with pg_dump
Date: 2011-05-05 14:34:36
Message-ID: 3223.1304606076@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

"gab" <korsani(at)free(dot)fr> writes:
> Try to restore it using :
> pg_restore -C -d test /tmp/plop
> pg_restore: [archiver (db)] connection to database "test" failed: FATAL:
> database "test" does not exist

> But the doc says that -C use the parameter of -d to CREATE the database ...

Well, if the docs say that they shouldn't. When you use -C, the
database named by -d is just the one where pg_restore initially connects
to issue the CREATE DATABASE command. Please specify where you think
the documentation is telling you something else.

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message gab 2011-05-05 15:04:41 BUG #6008: Can't contact Tom Lane :)
Previous Message Dave Page 2011-05-05 13:41:56 Re: BUG #6006: Will not install