Re: Shared Objects (Dynamic loading)

From: Michael Fuhr <mike(at)fuhr(dot)org>
To: Jasbinder Bali <jsbali(at)gmail(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Shared Objects (Dynamic loading)
Date: 2006-08-26 20:10:31
Message-ID: 20060826201031.GA46204@winnie.fuhr.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-novice

On Sat, Aug 26, 2006 at 03:32:37PM -0400, Jasbinder Bali wrote:
> Do we have any concept of shared objects in perl.
> Just wondering, how do we dynamically load something written in perl in
> postgresql.

A PL/Perl function can load external code with "use", "require",
or "do". Since those are potentially dangerous operations you'll
need to create the function with plperlu, which means you'll need
to create the function as a database superuser. See "Trusted and
Untrusted PL/Perl" in the documentation for more information.

http://www.postgresql.org/docs/8.1/interactive/plperl-trusted.html

Regarding "use", "require", and "do" see the Perl documentation,
in particular the perlfunc and perlmod manual pages.

--
Michael Fuhr

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Jim 2006-08-26 20:16:40 Fwd: Can't populate database using Copy
Previous Message Silvela, Jaime (Exchange) 2006-08-26 20:03:05 Re: mising chunk

Browse pgsql-novice by date

  From Date Subject
Next Message Julian Hagenauer 2006-08-27 14:21:20 JAVA_OBJECT: Unkown type
Previous Message Jasbinder Bali 2006-08-26 19:32:37 Re: Shared Objects (Dynamic loading)