Re: regex back-references?

From: Michael Blakeley <mike(at)blakeley(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-general(at)postgreSQL(dot)org
Subject: Re: regex back-references?
Date: 2000-08-21 19:56:49
Message-ID: p05000e36b5c72abea3d7@blakeley.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

At 1:30 AM -0400 8/21/2000, Tom Lane wrote:
>Michael Blakeley <mike(at)blakeley(dot)com> writes:
>> Does postgresql support regex back-references?
>
>There's no such function at the SQL level, AFAIR.
>
>I'd recommend writing a function in either plperl or pltcl, according
>to your taste. Both offer pretty much all the string-bashing
>functionality you could possibly want ...

Sounds like a plan - but I can't seem to create a function - can
anyone tell me what I'm doing wrong? A brief check of the archives
didn't turn up any hints...

Solaris 2.6, Postgresql 7.0.1, Perl 5.6, gcc 2.95.2.

After compiling and installing with
./configure --with-perl --without-tcl

psql=# CREATE FUNCTION pltest(VARCHAR) RETURNS VARCHAR AS
'return $_[0]' LANGUAGE 'plperl';
ERROR: Unrecognized language specified in a CREATE FUNCTION:
'plperl'. Recognized languages are sql, C, internal and the created
procedural languages.

Can I check for the presence of a .so somewhere? It seems to have
installed a couple in $PGSQL/lib:

-rwxr--r-- 1 root other 295784 Aug 21 12:47 plperl.so*
-rw-r--r-- 1 root other 690992 Aug 21 12:47 plpgsql.so

Also,

psql=# select * from pg_language;
lanname | lanispl | lanpltrusted | lanplcallfoid | lancompiler
----------+---------+--------------+---------------+-------------
internal | f | f | 0 | n/a
C | f | f | 0 | /bin/cc
sql | f | f | 0 | postgres
(3 rows)

Do I need to tell postgres to rebuild pg_language, perhaps?

thanks,
-- Mike

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Jessica Engblom 2000-08-21 20:13:44 Foreign Key Storage
Previous Message Craig L. Ching 2000-08-21 14:23:46 RE: Re: [SQL] database design and diagraming book recom mendations..