From: Oliver Elphick <olly@lfix.co.uk>
To: nickf@ontko.com
Cc: pgsql-admin <pgsql-admin@postgresql.org>
Subject: Re: pg_restore error: function plpgsql_call_handler
Date: 27 Nov 2002 14:00:50 +0000
Message-ID: <1038405650.13298.85.camel@linda.lfix.co.uk> (raw)
In-Reply-To: <NEBBLAAHGLEEPCGOBHDGMEPEGDAA.nickf@ontko.com>
References: <NEBBLAAHGLEEPCGOBHDGMEPEGDAA.nickf@ontko.com>
On Wed, 2002-11-27 at 13:16, Nick Fankhauser wrote:
> Hi-
>
> I'm trying to do a dump & restore of a complete database using tar archive
> format. I've previously used the text dump approach, so I'm very new to this
> method.
>
> I created the dump using:
>
> pg_dump -Ft alpha > alpha.dump.tar
>
>
> I'm trying to restore into an empty db using:
>
> pg_restore -d alpha2 alpha.dump.tar
>
> and I get this error:
>
> pg_restore: [archiver (db)] could not execute query: ERROR: function
> plpgsql_call_handler already exists with same argument types
>
> I found a brief mention of this error in an old novice list posting, but it
> seemed to be connected to a plain text dump file, so I'm still mystified.
>
> Any thoughts?
It sounds as though you are trying to restore an item which is already
in the database. Perhaps this snippet from the pg_restore man page may
be relevent:
If your installation has any local additions to the template1
database, be careful to load the output of pg_restore into a
truly empty database; otherwise you are likely to get errors due
to duplicate definitions of the added objects. To make an empty
database without any local additions, copy from template0 not
template1, for example:
CREATE DATABASE foo WITH TEMPLATE = template0;
--
Oliver Elphick <olly@lfix.co.uk>
LFIX Limited
Attachments:
signature.asc (application/pgp-signature, 188B) download
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-admin@postgresql.org
Cc: olly@lfix.co.uk, nickf@ontko.com
Subject: Re: pg_restore error: function plpgsql_call_handler
In-Reply-To: <1038405650.13298.85.camel@linda.lfix.co.uk>
References: <NEBBLAAHGLEEPCGOBHDGMEPEGDAA.nickf@ontko.com> <1038405650.13298.85.camel@linda.lfix.co.uk>
* 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