Re: BUG #3760: Comment on restore database

Поиск
Список
Период
Сортировка
От Bruce Momjian
Тема Re: BUG #3760: Comment on restore database
Дата
Msg-id 200711191841.lAJIfkU29118@momjian.us
обсуждение исходный текст
Ответ на BUG #3760: Comment on restore database  ("Malcus Imhof" <malcus@terra.com.br>)
Ответы Re: BUG #3760: Comment on restore database  (Alvaro Herrera <alvherre@alvh.no-ip.org>)
Re: BUG #3760: Comment on restore database  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-bugs
Malcus Imhof wrote:
>
> The following bug has been logged online:
>
> Bug reference:      3760
> Logged by:          Malcus Imhof
> Email address:      malcus@terra.com.br
> PostgreSQL version: 8.2.5
> Operating system:   Windows 2003
> Description:        Comment on restore database
> Details:
>
> When I'm restoring a dump done in a database called "client" on a new
> database called "new_database" shows a error when the pg_restore try to
> restore the comment:
>
> C:\Arquivos de programas\pgAdmin III\1.8\pg_restore.exe -i -h 192.168.0.11
> -p 5432 -U postgres -d "new_database" -v "C:\Documents and
> Settings\Ciro\Desktop\client.backup"
> pg_restore: connecting to database for restore
> pg_restore: creating COMMENT DATABASE "client"
> pg_restore: WARNING:  database "client" does not exist

Yea, the dump thinks it is going into the same database.  I don't see
any way of fixing that.  We don't allow functions for the object name.
If we did we could use current_database().  Fortunately I think it is
the only place where the database name is hardcoded in the dump.

I have added a TODO item:

        o Allow COMMENT ON dbname to work when loading into a database
          with a different name

--
  Bruce Momjian  <bruce@momjian.us>        http://momjian.us
  EnterpriseDB                             http://postgres.enterprisedb.com

  + If your life is a hard drive, Christ can be your backup. +

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

Предыдущее
От: Magnus Hagander
Дата:
Сообщение: Re: 8.3b2: problem using "COPY ... TO/FROM .... BINARY"
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: BUG #3760: Comment on restore database