Re: Is there a way to backup Postgres via SQL commands?

Поиск
Список
Период
Сортировка
От Merlin Moncure
Тема Re: Is there a way to backup Postgres via SQL commands?
Дата
Msg-id AANLkTimaEGTfodKvEjh-mv6RTcFpIGm8gpG4myFsxtPK@mail.gmail.com
обсуждение исходный текст
Ответ на Is there a way to backup Postgres via SQL commands?  (Frank Church <voipfc@googlemail.com>)
Список pgsql-general
On Mon, Jun 14, 2010 at 7:28 AM, Frank Church <voipfc@googlemail.com> wrote:
> Are there SQL commands that can do a backup over a client connection,
> rather than from the command line like pgsql etc?
>
> By that I mean some kind of SELECT commands that can retrieve the
> database's content as SQL commands that can be replayed to a server to
> restore it, rather than something that saves directly to file, or
> passes it through a pipe?

no -- it's actually possible for some trivial things (just grabbing a
few tables) -- but anything more complicated will quickly become
unreasonably difficult.

TBH, I think backups through SQL are quite nice.  Judging by the
standard of other databases, I generally always prefer the sql version
to the command line variant with both tools are available.

It would also be nice to be able to generate a restorable script from
any userland object.  pg_dump/pg_restore gives you the ability to
specifically grab indexes, functions, table, and triggers, but that's
it.

merlin

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

Предыдущее
От: Craig Ringer
Дата:
Сообщение: Re: What are the minimal files required to backup a postgresql database
Следующее
От: Gaurav K Srivastav
Дата:
Сообщение: Trigger get dissabled