Re: Postgres12 - Confusion with pg_restore

Поиск
Список
Период
Сортировка
От Laura Smith
Тема Re: Postgres12 - Confusion with pg_restore
Дата
Msg-id hFqAaHJzjLuVOICQpkqZg85tNRMME-i2UsGK-5SVst7NNstNPco9oRFhxztD2xnc8M0AVWh111b4F0P5zDgzazENq-L5Br_LSJkM7Uc2lCQ=@protonmail.ch
обсуждение исходный текст
Ответ на Re: Postgres12 - Confusion with pg_restore  (Christophe Pettus <xof@thebuild.com>)
Ответы Re: Postgres12 - Confusion with pg_restore  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general


Sent with ProtonMail Secure Email.

‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐
On Friday, 5 June 2020 19:23, Christophe Pettus <xof@thebuild.com> wrote:

> > On Jun 5, 2020, at 11:20, Laura Smith n5d9xq3ti233xiyif2vp@protonmail.ch wrote:
> > sudo -u postgres pg_restore -v -C -d foobar 4_foobar_pgdump_Fc
>
> You need to connect to a database that already exists (such as "postgres"); it then creates the database you are
restoringand switches to it. The relevant manual line is: 
>
> "When (-C / --create) is used, the database named with -d is used only to issue the initial DROP DATABASE and CREATE
DATABASEcommands. All data is restored into the database name that appears in the archive." 
>
>

But doesn't the second half of my original post demonstrate that I tried that very thing  ?  I did try creating the
databasefirst, but pg_restore just complained even more ? 



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

Предыдущее
От: Christophe Pettus
Дата:
Сообщение: Re: Postgres12 - Confusion with pg_restore
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Postgres12 - Confusion with pg_restore