Re: Restoring to a certain schema - Mailing list pgsql-general

From Richard Huxton
Subject Re: Restoring to a certain schema
Date
Msg-id 200302201023.54420.dev@archonet.com
Whole thread Raw
In response to Restoring to a certain schema  ("Opis Boi" <anci@centrin.net.id>)
List pgsql-general
On Thursday 20 Feb 2003 4:59 am, Opis Boi wrote:
> Dear All
>
> I have a dump file from v7.2.3 and wanted to restore it to a certain schema
> in v7.3.2 ( let's call it the abc schema ). The abc schema is also not the
> same with my username.
> So, if I take a look at the search_path, the $user,public won't take me
> there. How do I do that ?
> I've take look on the pg_restore options but it seems none of the option
> provides the solution. Any idea ? ( except to restore it to the public and
> copy the tables to the abc schema ? )

Try "SET search_path = mynewschema;" at the top of the pg_dump file. I'd have
thought that should do the trick.
--
  Richard Huxton

pgsql-general by date:

Previous
From: Richard Huxton
Date:
Subject: Re: Removing spaces
Next
From: Richard Huxton
Date:
Subject: Re: A problem with sequences...