BUG #1831: plperl gives error after reconnect.

From: "Greg Sabino Mullane" <greg(at)turnstep(dot)com>
To: pgsql-bugs(at)postgresql(dot)org
Subject: BUG #1831: plperl gives error after reconnect.
Date: 2005-08-17 19:52:54
Message-ID: 20050817195254.BFDAFF0C13@svr2.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs


The following bug has been logged online:

Bug reference: 1831
Logged by: Greg Sabino Mullane
Email address: greg(at)turnstep(dot)com
PostgreSQL version: 8.0.3
Operating system: Linux
Description: plperl gives error after reconnect.
Details:

Tested on 8.0.1 and in current cvs. This only happens if all the steps below
are followed, including the reconnect.

\c postgres

CREATE TABLE g (name TEXT);

CREATE OR REPLACE FUNCTION testone() RETURNS text LANGUAGE plperl AS
$$
spi_exec_query(qq{INSERT INTO g(name) VALUES ('abc')});
return "ok";
$$;

CREATE OR REPLACE FUNCTION enamer() RETURNS TRIGGER LANGUAGE plperl AS
$$
return;
$$;
CREATE TRIGGER trigtest BEFORE INSERT ON g FOR EACH ROW EXECUTE PROCEDURE
enamer();

\c postgres

select testone();

ERROR: error from Perl function: creation of Perl function failed:
(in cleanup) Undefined subroutine &main::mksafefunc called at (eval 4) line
2. at (eval 4) line 2.

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2005-08-17 22:46:20 Re: BUG #1831: plperl gives error after reconnect.
Previous Message Bruno Wolff III 2005-08-17 11:51:12 Re: BUG #1830: Non-super-user must be able to copy from a file