Re: pg_restore error: function plpgsql_call_handleralready exists with same argument types - Mailing list pgsql-admin

From Nick Fankhauser
Subject Re: pg_restore error: function plpgsql_call_handleralready exists with same argument types
Date
Msg-id NEBBLAAHGLEEPCGOBHDGEEPMGDAA.nickf@ontko.com
Whole thread Raw
In response to Re: pg_restore error: function plpgsql_call_handler  (Oliver Elphick <olly@lfix.co.uk>)
Responses Re: pg_restore error: function plpgsql_call_handleralready  (Oliver Elphick <olly@lfix.co.uk>)
Re: pg_restore error: function plpgsql_call_handleralready exists with same argument types  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-admin
Oliver-

Thanks for the idea. Unfortunately, it still won't go.

We've never touched template1, but just to make sure, I tried using
template0 to ensure an empty DB with the same results:

nickf@morgai:~$ createdb -D PG_ALPHA -T template0 test
CREATE DATABASE
nickf@morgai:~$ pg_restore -dalpha  test.dump.tar
pg_restore: [archiver (db)] could not execute query: ERROR:  function
plpgsql_call_handler already exists with same argument types
nickf@morgai:~$

I'm a bit surprised about this one, because we're running a plain 7.2
(debian package) installation & it seems as if this is a standard sort of
operation that other people would be using often.

-Nick


> 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;


pgsql-admin by date:

Previous
From: Oliver Elphick
Date:
Subject: Re: pg_restore error: function plpgsql_call_handler
Next
From: "Rajesh Kumar Mallah."
Date:
Subject: Re: TR: Starting the database server (2)