plperl

Does PostgreSQL keep its pl* interpreters loaded persistently?

If I wrote something in plperlu, when would that module be reloaded? Every time the function ran? The first time it ran? Does the Perl DLL get unloaded if it hasn't been used in a while, and then after that it'd be another module reload? ...

Does plperlu reload Perl modules if they change?

If I wrote something in plperlu, and it used a Perl module (e.g. MyModule::Foo), when would that module be reloaded? Does it keep track of them like mod_perl's Apache2::Reload, so that a touch will cause a reinterpretation? ...

IP address stored as decimal - PL/SQL to display as dotted quad.

We have an Oracle database that contains IP addresses stored as decimal integers - this is incredibly painful when manipulating the data by hand instead of via the web interface, yet hand manipulation is really handy as the network guys continually ask us to do strange things that the web interface authors did not anticipate. Could some...

Postgresql - how to disallow use of spaces in some string fields

I want to disallow the use of spaces in some text/varchar fields. Even more, it would be best to have only a set of characters that are allowed to use there, like: [a-zA-Z0-9_\-] And I want to make it as a rule to all VARCHAR fields that are members of primary key in their tables. This should be done on the database level and could...

How can I call a PL/Perl function from another PL/Perl function?

CREATE FUNCTION foo() RETURNS text LANGUAGE plperl AS $$ return 'foo'; $$; CREATE FUNCTION foobar() RETURNS text LANGUAGE plperl AS $$ return foo() . 'bar'; $$; I'm trying to compose results using multiple functions, but when I call foobar() I get an empty result. ...

can you use libraries in PL/Perl

I'm just curious if when writing PL/Perl functions if I can have a use My::Lib; statement, or enable pragma's and features (e.g. 'use strict; use feature 'switch';). ...