bug in pg_restore

Поиск
Список
Период
Сортировка
От Jeffrey W. Baker
Тема bug in pg_restore
Дата
Msg-id 1011396526.19728.6.camel@heat
обсуждение исходный текст
Ответы Re: bug in pg_restore  (Stephan Szabo <sszabo@megazone23.bigpanda.com>)
Список pgsql-general
I think there is a little bug in pg_restore.  It says it can't restore
because the database doesn't exist, but then if I create the database it
says it can't proceed because the database DOES exist.  The solution for
me was to omit the -C argument, but it looks like a bug to me:

pg@carlito:/bigraid/tmp$ pg_restore -C -F custom -d rupert -v rupert.dump
pg_restore: connecting to database for restore
pg_restore: [archiver (db)] connection to database "rupert" failed: FATAL 1:  Database "rupert" does not exist in the
systemcatalog. 
pg_restore: *** aborted because of error
pg@carlito:/bigraid/tmp$ createdb rupert
CREATE DATABASE
pg@carlito:/bigraid/tmp$ pg_restore -C -F custom -d rupert -v rupert.dump
pg_restore: connecting to database for restore
pg_restore: creating DATABASE rupert
pg_restore: [archiver (db)] could not execute query: ERROR:  CREATE DATABASE: database "rupert" already exists
pg_restore: *** aborted because of error
pg@carlito:/bigraid/tmp$ pg_restore -F custom -d rupert -v rupert.dump
pg_restore: connecting to database for restore
pg_restore: creating SEQUENCE request_id
...


The dump file was created with the -C argument.

Regards,
Jeffrey


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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: Need book on PHP and PostgreSQL
Следующее
От: Stephan Szabo
Дата:
Сообщение: Re: bug in pg_restore