From: Tom Lane <tgl@sss.pgh.pa.us>
To: Andreas Haumer <andreas@xss.co.at>
Cc: pgsql-admin@postgresql.org
Subject: Re: Restore dump into different databases/owners
Date: Sat, 12 Jan 2008 13:40:13 -0500
Message-ID: <16896.1200163213@sss.pgh.pa.us> (raw)
In-Reply-To: <47890687.8030504@xss.co.at>
References: <4788B647.1050600@xss.co.at>
<4788EA09.4050808@xss.co.at>
<9118.1200158125@sss.pgh.pa.us>
<47890687.8030504@xss.co.at>
Andreas Haumer <andreas@xss.co.at> writes:
> Tom Lane schrieb:
>> Exactly what problems did you have using "-O -U user" ?
> So, the main problem is the call to
> CREATE PROCEDURAL LANGUAGE plpgsql;
> on the "mwdb" schema which contains all the tables, functions etc.
Right. As of 8.3, the default permissions arrangement will allow
database owners to create trusted procedural languages for themselves,
so this dump would work for a non-superuser (though you'd still have
to ignore the error from attempting to comment SCHEMA public --- I
suppose we ought to look into keeping pg_dump from emitting that
comment).
Otherwise, the recommended procedure is for the superuser to load
any required procedural languages when he makes the empty database.
The database owner can take it from there.
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-admin@postgresql.org
Cc: tgl@sss.pgh.pa.us, andreas@xss.co.at
Subject: Re: Restore dump into different databases/owners
In-Reply-To: <16896.1200163213@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox