Re: Changing schema name when restoring?

From: Guillaume Lelarge <guillaume(at)lelarge(dot)info>
To: "Don O'Hara" <don(dot)ohara(at)gmail(dot)com>
Cc: "pgsql-admin(at)postgresql(dot)org" <pgsql-admin(at)postgresql(dot)org>
Subject: Re: Changing schema name when restoring?
Date: 2016-03-03 20:38:21
Message-ID: CAECtzeU-diZPfkqubwiLkwVXp9NLnGsCDA1Hjhb-DQUjpmCEJg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

2016-03-03 19:41 GMT+01:00 Don O'Hara <don(dot)ohara(at)gmail(dot)com>:

> I don't see anything in the documentation for pg_restore, but was curious
> if there is any way to restore to a schema name that is different from what
> it was unloaded from. I.E. I'd like to generate a TOC list using pg_restore
> and edit the schema name in that.
>
> Generating plain text output and editing the file is not an option due to
> dataset size.
>
> I have been restoring to the same schema name, then renaming the schema,
> but was looking if there are other ways to do it.
>

Nope, no nicer way.

--
Guillaume.
http://blog.guillaume.lelarge.info
http://www.dalibo.com

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message drum.lucas@gmail.com 2016-03-03 20:42:13 Re: pg_dump limit 1000 rows
Previous Message Don O'Hara 2016-03-03 18:41:52 Changing schema name when restoring?