Re: pg_dump design problem (bug??)

Поиск
Список
Период
Сортировка
От Karl O. Pinc
Тема Re: pg_dump design problem (bug??)
Дата
Msg-id 1147208781l.18374l.19l@mofo
обсуждение исходный текст
Ответ на Re: pg_dump design problem (bug??)  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: pg_dump design problem (bug??)  ("Nikolay Samokhvalov" <samokhvalov@gmail.com>)
Список pgsql-general
On 05/09/2006 03:47:20 PM, Tom Lane wrote:
> "Karl O. Pinc" <kop@meme.com> writes:
> > I'm wondering if there's a problem with pg_dump --create,
> > or if I'm just missing something.
> > It does not seem to restore things like:
> > ALTER DATABASE foo SET "DateStyle" TO European;
> > Shouldn't the database that is re-created be like
> > the database that is being dumped?
>
> I don't see any particular problem with leaving it to pg_dumpall, in
> any case.  pg_dump is already assuming that you've correctly set up
> cluster-wide state; for example it doesn't create users for you.

Thing is, I don't see the ALTER DATABASE x SET ... to be part of
a cluster-wide structure, I see it as belonging to a database.
(I do see your point as far as database owners go.)
The convenient way to backup and restore a single database
is to use pg_dump.  I could do a pg_dumpall --schema-only and
then remove everything not having to do with the specific db
I'm interested in when I want to, say, copy a database from
one machine to another, but it's a hassle.

The SETs make a big difference.  I was looking in the wrong
schema because I didn't restore my database's my search_path
properly.

Karl <kop@meme.com>
Free Software:  "You don't pay back, you pay forward."
                  -- Robert A. Heinlein


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

Предыдущее
От: John Purser
Дата:
Сообщение: Re: install postgres on usb drive???
Следующее
От: "Rodrigo Cortés"
Дата:
Сообщение: Re: install postgres on usb drive???