Re: [GENERAL] pl/perl and recent perl versions - failing to load internal modules

2014-07-01 Thread Alex Hunsaker
On Tue, Jul 1, 2014 at 7:31 PM, Alex Hunsaker wrote: > On Tue, Jul 1, 2014 at 6:39 PM, Toby Corkindale > wrote: >> Hi Alex, >> However the following code fails: >> => do $$ "\N{U+263A}" =~ /[[:punct:]]/$$ language plperl; >> ERROR: Unable to load utf8.pm into plperl at line 1. >> BEGIN failed-

Re: [GENERAL] pl/perl and recent perl versions - failing to load internal modules

2014-07-01 Thread Alex Hunsaker
On Tue, Jul 1, 2014 at 6:39 PM, Toby Corkindale wrote: > Hi Alex, > your example (chr(0x100) =~ /\\xa9/) works on my instance (pg 9.3.4, plperl > 5.18) > However the following code fails: > => do $$ "\N{U+263A}" =~ /[[:punct:]]/$$ language plperl; > ERROR: Unable to load utf8.pm into plperl at

Re: [GENERAL] pl/perl and recent perl versions - failing to load internal modules

2014-07-01 Thread Toby Corkindale
To: "Toby Corkindale" > Cc: "pgsql-general" > Sent: Wednesday, 2 July, 2014 9:28:52 AM > Subject: Re: [GENERAL] pl/perl and recent perl versions - failing to load > internal modules > > On Mon, Jun 30, 2014 at 7:47 PM, Toby Corkindale > wrote: > >

Re: [GENERAL] pl/perl and recent perl versions - failing to load internal modules

2014-07-01 Thread Toby Corkindale
Corkindale" > Cc: "pgsql-general" > Sent: Wednesday, 2 July, 2014 9:28:52 AM > Subject: Re: [GENERAL] pl/perl and recent perl versions - failing to load > internal modules > > On Mon, Jun 30, 2014 at 7:47 PM, Toby Corkindale > wrote: > > Hi, >

Re: [GENERAL] pl/perl and recent perl versions - failing to load internal modules

2014-07-01 Thread Alex Hunsaker
On Mon, Jun 30, 2014 at 7:47 PM, Toby Corkindale wrote: > Hi, > I've been trying out PostgreSQL 9.3 with pl/perl built against Ubuntu 14.04 > LTS' Perl 5.18 > (Sourced from apt.postgresql.org) > > Maybe I'm doing something wrong, but it appears that plperl has become > completely useless, as it

[GENERAL] pl/perl and recent perl versions - failing to load internal modules

2014-06-30 Thread Toby Corkindale
Hi, I've been trying out PostgreSQL 9.3 with pl/perl built against Ubuntu 14.04 LTS' Perl 5.18 (Sourced from apt.postgresql.org) Maybe I'm doing something wrong, but it appears that plperl has become completely useless, as it can't load any new modules, but modern Perl versions have refactored

Re: [GENERAL] Pl/perl and perl version-tip in doc

2011-01-06 Thread Richard Huxton
On 06/01/11 18:07, pasman pasmański wrote: It is need tip in doc which version of perl must be installed. Error message tells nothing. For example Postgres 8.4 works only with perl 5.10. Are you sure that's the case? Could it be that you're using a pre-compiled version of plperl? -- Richar

[GENERAL] Pl/perl and perl version-tip in doc

2011-01-06 Thread pasman pasmański
It is need tip in doc which version of perl must be installed. Error message tells nothing. For example Postgres 8.4 works only with perl 5.10. -- Sent from my mobile device pasman -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscr

Re: [GENERAL] pl/perl interpreter instance(s) - how long does it persist?

2010-12-08 Thread Toby Corkindale
On 09/12/10 13:37, Tom Lane wrote: Toby Corkindale writes: I would like to know how long the pl/perl interpreter instances persist? Till end of session. Where session = connection (whether from psql, DBI, etc), yes? Initial testing seems to give me contrary results. In some cases, creati

Re: [GENERAL] pl/perl interpreter instance(s) - how long does it persist?

2010-12-08 Thread Tom Lane
Toby Corkindale writes: > I would like to know how long the pl/perl interpreter instances persist? Till end of session. > Initial testing seems to give me contrary results. > In some cases, creating a new DB then loading the same module in a new > stored procedure will get the old version. > Bu

Re: [GENERAL] pl/perl object destruction (or lack thereof) at session end

2010-12-08 Thread Toby Corkindale
On 09/12/10 13:00, Toby Corkindale wrote: Hi, Looking at this: http://www.postgresql.org/docs/9.0/interactive/plperl-under-the-hood.html Specifically, the "known limitations" part, I see it says: When a session ends normally, not due to a fatal error, any END blocks that have been defined are ex

[GENERAL] pl/perl interpreter instance(s) - how long does it persist?

2010-12-08 Thread Toby Corkindale
Hi, Apologies in advance if this has been covered before, but I've searched extensively without finding anything so far. I would like to know how long the pl/perl interpreter instances persist? I ask because I'm doing some work where we have PL/Perlu code that loads some Perl modules in trigg

[GENERAL] pl/perl object destruction (or lack thereof) at session end

2010-12-08 Thread Toby Corkindale
Hi, Looking at this: http://www.postgresql.org/docs/9.0/interactive/plperl-under-the-hood.html Specifically, the "known limitations" part, I see it says: When a session ends normally, not due to a fatal error, any END blocks that have been defined are executed. Currently no other actions ar

Re: [GENERAL] pl-perl for 64 bits in Solaris 9

2010-07-09 Thread Felipe de Jesús Molina Bravo
well after many problems i can install sunstudio 11; but now my problem is: > > > - environment: > bash-2.05# echo $CC > /opt/SunStudio/bin/cc > > bash-2.05# echo $CFLAGS > -xarch=v9 -O > > - my configure was: > > ./configure --with-CC=/opt/SunStudio/bin/cc --with-perl --without-readline

Re: [GENERAL] pl-perl for 64 bits in Solaris 9

2010-07-07 Thread Felipe de Jesús Molina Bravo
El 26 de junio de 2010 16:56, Felipe de Jesús Molina Bravo < fjmolinabr...@gmail.com> escribió: > > > 2010/6/25 John R Pierce > >> On 06/25/10 9:28 PM, Felipe de Jesús Molina Bravo wrote: >> >> original perl is 5.6. so i installed perl 5.8.9 for 64 bit and the >>> error is the same... maybe m

Re: [GENERAL] pl-perl for 64 bits in Solaris 9

2010-06-26 Thread Felipe de Jesús Molina Bravo
2010/6/25 John R Pierce > On 06/25/10 9:28 PM, Felipe de Jesús Molina Bravo wrote: > >> original perl is 5.6. so i installed perl 5.8.9 for 64 bit and the >> error is the same... maybe my error is with the compiler, it is "gcc" >> (3.4.6). is it possible? >> > > where did this 64bit 5.8.9 c

Re: [GENERAL] pl-perl for 64 bits in Solaris 9

2010-06-25 Thread John R Pierce
On 06/25/10 9:28 PM, Felipe de Jesús Molina Bravo wrote: original perl is 5.6. so i installed perl 5.8.9 for 64 bit and the error is the same... maybe my error is with the compiler, it is "gcc" (3.4.6). is it possible? where did this 64bit 5.8.9 come from? I try to downloaded SunStudio

Re: [GENERAL] pl-perl for 64 bits in Solaris 9

2010-06-25 Thread Felipe de Jesús Molina Bravo
2010/6/25 John R Pierce > On 06/25/10 2:21 PM, MOLINA BRAVO FELIPE DE JESUS wrote: > >> Hi >> >> I don't have experience with solaris. I know it is a 64 bits: >> >> bash-2.05# isainfo -v >> 64-bit sparcv9 applications >> 32-bit sparc applications >> >> >> >> I tried to compile postgres (Version o

Re: [GENERAL] pl-perl for 64 bits in Solaris 9

2010-06-25 Thread John R Pierce
On 06/25/10 2:21 PM, MOLINA BRAVO FELIPE DE JESUS wrote: Hi I don't have experience with solaris. I know it is a 64 bits: bash-2.05# isainfo -v 64-bit sparcv9 applications 32-bit sparc applications I tried to compile postgres (Version of postgres: 8.4.4 ) with plperl for 64 bits. The option

[GENERAL] pl-perl for 64 bits in Solaris 9

2010-06-25 Thread MOLINA BRAVO FELIPE DE JESUS
Hi I don't have experience with solaris. I know it is a 64 bits: bash-2.05# isainfo -v 64-bit sparcv9 applications 32-bit sparc applications I tried to compile postgres (Version of postgres: 8.4.4 ) with plperl for 64 bits. The options for the configure are: /configure --with-CC=/usr/local

[GENERAL] pl-perl for 64 bits in Solaris 9

2010-06-25 Thread Felipe de Jesús Molina Bravo
Hi I don't have experience with solaris. I know it is a 64 bits: bash-2.05# isainfo -v 64-bit sparcv9 applications 32-bit sparc applications I tried to compile postgres (Version of postgres: 8.4.4 ) with plperl for 64 bits. The options for the configure are: /configure --with-CC=/usr/local/bi

Re: [GENERAL] pl/perl setof function

2010-01-13 Thread Andy Colson
On 1/13/2010 1:26 PM, Andy Colson wrote: On 1/13/2010 12:20 PM, Alex - wrote: Hi, i have a PL/PERL RETURN SETOF function which processes a few 10k records. The processing takes quite some time and in order to display progress I use a return_next after every few thousand records. However, the fu

Re: [GENERAL] pl/perl setof function

2010-01-13 Thread Andy Colson
On 1/13/2010 12:20 PM, Alex - wrote: Hi, i have a PL/PERL RETURN SETOF function which processes a few 10k records. The processing takes quite some time and in order to display progress I use a return_next after every few thousand records. However, the function returns all messages when it comple

[GENERAL] pl/perl setof function

2010-01-13 Thread Alex -
Hi,i have a PL/PERL RETURN SETOF function which processes a few 10k records.The processing takes quite some time and in order to display progressI use a return_next after every few thousand records. However, the function returns all messages when it completes and exists which is not really what

Re: [GENERAL] pl/perl not rethrowing pl/pgsql exceptions

2010-01-05 Thread Merlin Moncure
On Tue, Jan 5, 2010 at 12:49 PM, Merlin Moncure wrote: > is this behavior correct? > > create or replace function error() returns text as > $$ > begin >  raise exception 'test!'; > end; > $$ language plpgsql; > > > create or replace function test() returns text as > $$ >  my $res = spi_query("sele

[GENERAL] pl/perl not rethrowing pl/pgsql exceptions

2010-01-05 Thread Merlin Moncure
is this behavior correct? create or replace function error() returns text as $$ begin raise exception 'test!'; end; $$ language plpgsql; create or replace function test() returns text as $$ my $res = spi_query("select error()"); # this error is ignored my $res = spi_query("something stupid

Re: [GENERAL] PL/Perl Performance Problems

2009-12-21 Thread Alex -
Thanks,I am already have started doing that. i.e. running the dummy task to get the tables loaded again and it worked fine today. regardsAlex > To: ainto...@hotmail.com > CC: scott.marl...@gmail.com; pgsql-general@postgresql.org > Subject: Re: [GENERAL] PL/Perl Performance Problem

Re: [GENERAL] PL/Perl Performance Problems

2009-12-20 Thread Tom Lane
Alex - writes: > Tom, Scott, Alvaro,thanks for the hints on this issue. It looks as if one of > the EOD maintenance jobs which does a few extensive queries does push data > out of memory leading to this behavior. > Is there a way to permanently cash some tables into memory? Not as such, and if

Re: [GENERAL] PL/Perl Performance Problems

2009-12-20 Thread Alex -
:10:36 -0700 > Subject: Re: [GENERAL] PL/Perl Performance Problems > From: scott.marl...@gmail.com > To: ainto...@hotmail.com > CC: t...@sss.pgh.pa.us; pgsql-general@postgresql.org > > According to your original post, you do selects in step 1 and 2... Or > is this a differe

Re: [GENERAL] PL/Perl Performance Problems

2009-12-18 Thread Alex -
simple inserts. after the insert the job will call the function and there i have the same issues. runs slow in the morning, and fast in the afternoon. it will pick up speed after 5-10k records thanks for your help > Date: Sat, 19 Dec 2009 00:10:36 -0700 > Subject: Re: [GENERAL] PL/Perl Perfo

Re: [GENERAL] PL/Perl Performance Problems

2009-12-18 Thread Scott Marlowe
wrote: > On a 2nd thought... where does the cach come into play when i only do > inserts and no selects. > Alex > >> Date: Fri, 18 Dec 2009 23:45:07 -0700 >> Subject: Re: [GENERAL] PL/Perl Performance Problems >> From: scott.marl...@gmail.com >> To: ainto...@hot

Re: [GENERAL] PL/Perl Performance Problems

2009-12-18 Thread Alex -
On a 2nd thought... where does the cach come into play when i only do inserts and no selects. Alex > Date: Fri, 18 Dec 2009 23:45:07 -0700 > Subject: Re: [GENERAL] PL/Perl Performance Problems > From: scott.marl...@gmail.com > To: ainto...@hotmail.com > CC: t...@sss.pgh.pa.us

Re: [GENERAL] PL/Perl Performance Problems

2009-12-18 Thread Alex -
18 Dec 2009 23:45:07 -0700 > Subject: Re: [GENERAL] PL/Perl Performance Problems > From: scott.marl...@gmail.com > To: ainto...@hotmail.com > CC: t...@sss.pgh.pa.us; pgsql-general@postgresql.org > > On Fri, Dec 18, 2009 at 11:37 PM, Alex - wrote: > > Hmm... > > how can

Re: [GENERAL] PL/Perl Performance Problems

2009-12-18 Thread Scott Marlowe
On Fri, Dec 18, 2009 at 11:37 PM, Alex - wrote: > Hmm... > how can that be. This is happening every day, so its not a one off or > happens once in the morning then in the afternoon. There is also no other > task running on the system, its dedicated to postgres. > Could the Autovacuum cause problem

Re: [GENERAL] PL/Perl Performance Problems

2009-12-18 Thread Alex -
day but the keep silent till the day timestamp breaks ? The think is that I have 4 servers setup in a similar way and all have exactly the same problem. > Date: Fri, 18 Dec 2009 23:00:16 -0700 > Subject: Re: [GENERAL] PL/Perl Performance Problems > From: scott.marl...@gmail.com &g

Re: [GENERAL] PL/Perl Performance Problems

2009-12-18 Thread Scott Marlowe
Note that you seem to have a lot more IO wait in the first run than in the second, which means that the task is hitting the disks more in the first run than in the second one. Once IO wait starts to climb, performance starts to dive, generally. -- Sent via pgsql-general mailing list (pgsql-gener

Re: [GENERAL] PL/Perl Performance Problems

2009-12-18 Thread Alex -
I run AutovacuumI run a Vaccum Full Analyze every SatI re-index the tables every Sat > Date: Fri, 18 Dec 2009 21:20:23 -0300 > From: alvhe...@commandprompt.com > To: ainto...@hotmail.com > CC: t...@sss.pgh.pa.us; pgsql-general@postgresql.org > Subject: Re: [GENERAL] PL/Perl Perfo

Re: [GENERAL] PL/Perl Performance Problems

2009-12-18 Thread Alvaro Herrera
Alex - wrote: > > Tom, I am logging these stats now, but i am having a similar issue. both jobs > in the morning and after noon insert about 400k records (200k each) > In the morning that job takes 450secIn the afternoon only 150; No select, > simple parsing a file and insert the records > These

Re: [GENERAL] PL/Perl Performance Problems

2009-12-18 Thread Alex -
0 1238 6720 2611 352 15 1 75 10 0 > To: ainto...@hotmail.com > CC: pgsql-general@postgresql.org > Subject: Re: [GENERAL] PL/Perl Performance Problems > Date: Fri, 18 Dec 2009 15:36:15 -0500 > From: t...@sss.pgh.pa.us > > Alex - writes: > > I actually looked

Re: [GENERAL] PL/Perl Performance Problems

2009-12-18 Thread Alex -
Thank, I will check that out. > To: ainto...@hotmail.com > CC: pgsql-general@postgresql.org > Subject: Re: [GENERAL] PL/Perl Performance Problems > Date: Fri, 18 Dec 2009 15:36:15 -0500 > From: t...@sss.pgh.pa.us > > Alex - writes: > > I actually looked at that to

Re: [GENERAL] PL/Perl Performance Problems

2009-12-18 Thread Tom Lane
Alex - writes: > I actually looked at that too, but there is no swapping going on. If you were only watching for swapping, that wouldn't catch what I'm talking about. Replacing cached disk buffers with other disk data doesn't count as swapping in any system I've used. re

Re: [GENERAL] PL/Perl Performance Problems

2009-12-18 Thread Alex -
I actually looked at that too, but there is no swapping going on. The system also has 16GB memory allocated to postgres and during the processing there is not other process really active. > To: ainto...@hotmail.com > CC: pgsql-general@postgresql.org > Subject: Re: [GENERAL] PL/Perl Pe

Re: [GENERAL] PL/Perl Performance Problems

2009-12-18 Thread Tom Lane
Alex - writes: > Now here is what I noticed. > a) if I run it in the morning, processing starts very slow, but after a few > thousand records it will speed up until I actually get about 100 records > processed per millisecond. > b) it sometime takes about 5-10k records till i really get up to sp

[GENERAL] PL/Perl Performance Problems

2009-12-18 Thread Alex -
Hi, I am experiencing some strange behavior when executing a not too complicated pl/perl function. The Function is not too complicated. It does... 1. Selects about 20 Records from Table A ( - loops though the list and deletes in total about 50k records in Table B2. For each record form Table A

Re: [GENERAL] PL/Perl 64-bit and sending emails

2009-09-04 Thread Dimitri Fontaine
Hi, Steve Atkins writes: > On Sep 3, 2009, at 11:30 AM, Mark Lubratt wrote: >> Or, does someone know of another way to get the >> backend to send an email? > > Have a queue table in the database you put your emails into and an external > process that polls the table, sends the email and deletes

Re: [GENERAL] PL/Perl 64-bit and sending emails

2009-09-03 Thread Steve Atkins
On Sep 3, 2009, at 11:30 AM, Mark Lubratt wrote: Hello! I've been running the 64-bit version of 8.3.4 on OpenSolaris 2009.06 for over a year. Now, I need to put a perl function call into it to allow emails to be sent by the database backend. I tried installing plperl, but it looks like

[GENERAL] PL/Perl 64-bit and sending emails

2009-09-03 Thread Mark Lubratt
Hello! I've been running the 64-bit version of 8.3.4 on OpenSolaris 2009.06 for over a year. Now, I need to put a perl function call into it to allow emails to be sent by the database backend. I tried installing plperl, but it looks like only a 32-bit version is available. Does the 64-

[GENERAL] PL/Perl: Is there a way to use spi_prepare/spi_exec_prepared with a list as second argument?

2009-05-05 Thread Markus Wollny
Hello! I'd like to dynamically prepare and execute a certain statement in PL/perl, i.e. I don't know at the time of calling my trigger function how many arguments I need to pass for this queries and which types they have. The command string is assembled dynamically, as is the list of type-identifi

Re: [GENERAL] Pl/;perl

2008-05-07 Thread Craig Ringer
George R. C. Silva wrote: > i have activeperl 5.1 installed and pgsql 8.3 You'll need ActivePerl 5.8 . -- Craig Ringer -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] Pl/;perl

2008-05-07 Thread George R. C. Silva
Hello All, I´m trying to install pl/perl in my windows machine, but for some reason it just wont work. createlang wont work, create language doesnt work either. i have activeperl 5.1 installed and pgsql 8.3 it returns me this error: 126 unknown - could not load library. any tips? Thanks G

Re: [GENERAL] pl/perl autonomous transactions question

2006-09-27 Thread Robert Treat
On Monday 25 September 2006 15:05, Bob wrote: > I would like to use autonomous transactions for a large batch process and I > want this all encapsulated within stored procedures. I want to commit after > say every 15,000 records. The only way I have found to do this is to use > the perl DBI in my s

Re: [GENERAL] pl/perl autonomous transactions question

2006-09-26 Thread Jim Nasby
On Sep 25, 2006, at 3:05 PM, Bob wrote: One issue I see with my current DBI solution is I need to hard code or pass in as variables the connection information. I would prefer not to have the password lying around in plain site. Keep in mind this is a batch process not a something I that i

[GENERAL] pl/perl autonomous transactions question

2006-09-25 Thread Bob
I would like to use autonomous transactions for a large batch process and I want this all encapsulated within stored procedures. I want to commit after say every 15,000 records. The only way I have found to do this is to use the perl DBI in my stored procedure to establish a new connection to the

Re: [GENERAL] PL/Perl questions...

2006-06-16 Thread David Fetter
On Fri, Jun 16, 2006 at 11:42:51AM -0500, LLC wrote: > Hi List; > > I have 2 questions... > > 1) I want to create a perl function which connects to an external > non-Postgres database and retrieves data. I wonder is the best way > to do this to return a set or an array? I assume returning a dat

[GENERAL] PL/Perl questions...

2006-06-16 Thread LLC
Hi List;   I have 2 questions...   1) I want to create a perl function which connects to an external non-Postgres database and retrieves data. I wonder is the best way to do this to return a set or an array? I assume returning a data set is a better way to go, I want to be able to run something lik

Re: [GENERAL] pl/perl error

2006-04-10 Thread Frank
On Sun, Apr 09, 2006 at 06:22:40PM -0400, Tom Lane wrote: > Frank <[EMAIL PROTECTED]> writes: > > I have a perl script running as a daemon. It's using DBD::Pg (1.43) to > > connect to my Postgres server (8.0.7) running on the same box and talking > > over a socket. When I start the server, it run

Re: [GENERAL] pl/perl error

2006-04-09 Thread Tom Lane
Frank <[EMAIL PROTECTED]> writes: > I have a perl script running as a daemon. It's using DBD::Pg (1.43) to > connect to my Postgres server (8.0.7) running on the same box and talking > over a socket. When I start the server, it runs fine for about a day, and > then at some point I start getting t

Re: [GENERAL] pl/perl error

2006-04-09 Thread Douglas McNaught
Frank <[EMAIL PROTECTED]> writes: > I have a perl script running as a daemon. It's using DBD::Pg (1.43) to > connect to my Postgres server (8.0.7) running on the same box and talking > over a socket. When I start the server, it runs fine for about a day, and > then at some point I start getting

[GENERAL] pl/perl error

2006-04-09 Thread Frank
I have a perl script running as a daemon. It's using DBD::Pg (1.43) to connect to my Postgres server (8.0.7) running on the same box and talking over a socket. When I start the server, it runs fine for about a day, and then at some point I start getting this error repeatedly: DBD::Pg::db do fail

Re: [GENERAL] PL/PERL: raise notice, exception ?

2005-04-05 Thread Jim C. Nasby
On Tue, Apr 05, 2005 at 07:37:03AM -0700, David Fetter wrote: > On Tue, Apr 05, 2005 at 04:28:10PM +0200, Philippe Lang wrote: > > Hi, > > > > Is there in PL/PERL, under PG 8.01, an equivalent for the "raise > > notice, exception" commands of PL/PGSQL? > > Use the elog() function. :) See also ht

Re: [GENERAL] PL/PERL: raise notice, exception ?

2005-04-05 Thread David Fetter
On Tue, Apr 05, 2005 at 04:28:10PM +0200, Philippe Lang wrote: > Hi, > > Is there in PL/PERL, under PG 8.01, an equivalent for the "raise > notice, exception" commands of PL/PGSQL? Use the elog() function. :) Cheers, D -- David Fetter [EMAIL PROTECTED] http://fetter.org/ phone: +1 510 893 6100

[GENERAL] PL/PERL: raise notice, exception ?

2005-04-05 Thread Philippe Lang
Hi, Is there in PL/PERL, under PG 8.01, an equivalent for the "raise notice, exception" commands of PL/PGSQL? Philippe ---(end of broadcast)--- TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]

Re: [GENERAL] PL/PERL with composite return values & PGSQL 7.4?

2005-04-01 Thread Tom Lane
"Philippe Lang" <[EMAIL PROTECTED]> writes: > Documentation mentions that PGSQL 8 supports a version of PL/PERL with > composite return values. Is there a way to install this new version of > PL/PERL on an old 7.4 database, No. The rest of it might work, but not that feature, at least not without

[GENERAL] PL/PERL with composite return values & PGSQL 7.4?

2005-04-01 Thread Philippe Lang
Hi, Documentation mentions that PGSQL 8 supports a version of PL/PERL with composite return values. Is there a way to install this new version of PL/PERL on an old 7.4 database, or is it absolutely necessary to upgrade? Thanks Philippe Lang ---(end of broadcast)-

Re: [GENERAL] pl/perl problem of memory

2005-03-25 Thread Tom Lane
"GIROIRE Nicolas (COFRAMI)" <[EMAIL PROTECTED]> writes: > In fact, now i put the variable to '' ( $myvar = '' ) but it seems that Perl > don't empty totally memory. See the nearby thread "plperl doesn't release memory". There's some evidence that this may be due to a Perl configuration issue.

[GENERAL] pl/perl problem of memory

2005-03-25 Thread GIROIRE Nicolas (COFRAMI)
Title: pl/perl problem of memory Hi, I load data in a varible of type text, and i arrive to out of memory message. I want to know if it exists a function which allows to empty a variable and the place uses in memory without destroy it (because I use the variable again). In fact, now i put

Re: [GENERAL] pl/perl problem

2005-03-23 Thread FERREIRA William (COFRAMI)
Title: RE: [GENERAL] pl/perl problem yes, it works exactly what i needed, thanks a lot -Message d'origine- De : Richard Huxton [mailto:dev@archonet.com] Envoyé : mardi 22 mars 2005 12:41 À : FERREIRA William (COFRAMI) Cc : 'Sean Davis'; pgsql-general@postgresql

Re: [GENERAL] pl/perl problem

2005-03-23 Thread FERREIRA William (COFRAMI)
Title: RE: [GENERAL] pl/perl problem thanks a lot with your example and the example of Richard it works fine -Message d'origine- De : Sean Davis [mailto:[EMAIL PROTECTED]] Envoyé : mardi 22 mars 2005 12:51 À : FERREIRA William (COFRAMI) Cc : pgsql-general@postgresql.org Objet

Re: [GENERAL] pl/perl problem

2005-03-22 Thread Sean Davis
On Mar 22, 2005, at 3:13 AM, FERREIRA William (COFRAMI) wrote: my function is very long but i found an example with the same comportment : CREATE OR REPLACE FUNCTION adoc.totoTest()   RETURNS int4 AS $BODY$  my $var = '->>>';  &concat($var);  sub concat {   $var .= 'tagada';  }  elog NOTICE, $var

Re: [GENERAL] pl/perl problem

2005-03-22 Thread Richard Huxton
FERREIRA William (COFRAMI) wrote: my function is very long but i found an example with the same comportment : CREATE OR REPLACE FUNCTION adoc.totoTest() RETURNS int4 AS $BODY$ my $var = '->>>'; &concat($var); sub concat { $var .= 'tagada'; } elog NOTICE, $var; return 4; $BODY$ LANGUAGE

Re: [GENERAL] pl/perl problem

2005-03-22 Thread FERREIRA William (COFRAMI)
essage d'origine-De : Sean Davis [mailto:[EMAIL PROTECTED]Envoyé : lundi 21 mars 2005 16:46À : FERREIRA William (COFRAMI); pgsql-general@postgresql.orgObjet : Re: [GENERAL] pl/perl problem   - Original Message - From: FERREIRA William (COFRAMI) To

Re: [GENERAL] pl/perl problem

2005-03-21 Thread Sean Davis
Title: RE: [GENERAL] Convert Cursor to array   - Original Message - From: FERREIRA William (COFRAMI) To: 'pgsql-general@postgresql.org' Sent: Monday, March 21, 2005 9:22 AM Subject: [GENERAL] pl/perl problem hi   i wrote a store procedure us

[GENERAL] pl/perl problem

2005-03-21 Thread FERREIRA William (COFRAMI)
Title: RE: [GENERAL] Convert Cursor to array hi   i wrote a store procedure using the pl/perlU language, and the comportment is strange. my procedure do a select on my database and some traitments too and write the result in a file;   when i run the procedure a first time, it works fine, th

Re: [GENERAL] PL/Perl trusted throws error on example function

2005-03-03 Thread Frank Finner
Hi Tom, I found an error right between my ears, means, I had looked at the client__s version of Safe, not thinking about the fact that I was connected to the database on a server which actually had Safe installed only with version 2.07. I upgraded Safe now from CPAN on my server and everything wo

Re: [GENERAL] PL/Perl trusted throws error on example function

2005-03-03 Thread Tom Lane
Frank Finner <[EMAIL PROTECTED]> writes: > error from Perl function: trusted Perl functions disabled - please > upgrade Perl Safe module to version 2.09 or later at (eval 4) line 1. What do you get from perl -e 'require Safe; print "$Safe::VERSION\n"' regards, tom

[GENERAL] PL/Perl trusted throws error on example function

2005-03-02 Thread Frank Finner
Hi, I tried to test plperl and got the following error with the very first example from chapter 37: CREATE OR REPLACE FUNCTION perlmax(integer,integer) RETURNS integer AS $$ if ($_[0] > $_[1]) { return $_[0]; } return $_[1]; $$ LANGUAGE plperl; -- error from Perl function: trusted Perl functions

Re: [GENERAL] PL/Perl

2005-01-11 Thread Joshua D. Drake
ON.KG wrote: Hi All! I'm trying in 'plperl' forking the processes by 'fork' function, but receiving this message Have you tried performing this with plperlU? Sincerely, Joshua D. Drake Warning: pg_exec(): Query failed: ERROR: creation of function failed: 'fork' trapped by operation mask at (ev

Re: [GENERAL] PL/Perl

2005-01-11 Thread Richard Huxton
ON.KG wrote: Hi All! I'm trying in 'plperl' forking the processes by 'fork' function, but receiving this message Warning: pg_exec(): Query failed: ERROR: creation of function failed: 'fork' trapped by operation mask at (eval 2) line 11. Does it mean, that in 'plperl' I can't use 'fork' function???

Re: [GENERAL] PL/Perl

2005-01-11 Thread Ragnar Hafstað
On Tue, 2005-01-11 at 14:59 +0300, ON.KG wrote: > I'm trying in 'plperl' forking the processes by 'fork' function, > but receiving this message > > Warning: pg_exec(): Query failed: ERROR: creation of function failed: 'fork' > trapped by operation mask at (eval 2) line 11. > > Does it mean, tha

[GENERAL] PL/Perl

2005-01-11 Thread ON.KG
Hi All! I'm trying in 'plperl' forking the processes by 'fork' function, but receiving this message Warning: pg_exec(): Query failed: ERROR: creation of function failed: 'fork' trapped by operation mask at (eval 2) line 11. Does it mean, that in 'plperl' I can't use 'fork' function??? function

Re: [GENERAL] PL/Perl

2005-01-07 Thread Joshua D. Drake
with me it doesn't work and returns error message "Query failed: ERROR: creation of function failed: 'require' trapped by operation mask at (eval 2) line 2. in ..." You need to use plperlu. Sincerely, Joshua D. Drake Thanx ---(end of broadcast)--- T

Re: [GENERAL] PL/Perl

2005-01-07 Thread Pavel Stehule
Hello, you have to use plperlu, untrusted plperl regards Pavel Stehule On Fri, 7 Jan 2005, ON.KG wrote: > Hi! > > Could I use "use", "require" functions in plperl? > > for example, > > CREATE OR REPLACE FUNCTION perl_func (text) > RETURNS real > AS ' > use HTTP::Request; > use HTTP::Head

[GENERAL] PL/Perl

2005-01-07 Thread ON.KG
Hi! Could I use "use", "require" functions in plperl? for example, CREATE OR REPLACE FUNCTION perl_func (text) RETURNS real AS ' use HTTP::Request; use HTTP::Headers; return $value; ' LANGUAGE 'plperl'; with me it doesn't work and returns error message "Query failed: ERROR: creati

Re: [GENERAL] Pl/Perl w/ Postgres 8.0 on Windows

2004-12-02 Thread Eric E
Thanks to both of you gentlemen. I actually had to restart Postgres after installing ActiveState Perl before I could successfully run createlang and add the language. Seems to be working now, though. Cheers, Eric Magnus Hagander wrote: Hi all, I am throughly enjoying using Postgres 8.0 on W

Re: [GENERAL] Pl/Perl w/ Postgres 8.0 on Windows

2004-12-02 Thread Magnus Hagander
> Hi all, > I am throughly enjoying using Postgres 8.0 on Windows, so > I can develop my Windows client against Postgres. > I would like to write some pl/perl functions, and I'm a > little stumped. > Now comes the sad confession - I installed PG from the > Windows installer rather than bu

[GENERAL] Pl/Perl w/ Postgres 8.0 on Windows

2004-12-01 Thread Eric E
Hi all, I am throughly enjoying using Postgres 8.0 on Windows, so I can develop my Windows client against Postgres. I would like to write some pl/perl functions, and I'm a little stumped. Now comes the sad confession - I installed PG from the Windows installer rather than building it. Can

Re: [GENERAL] Pl/Perl speed

2004-01-14 Thread Joshua D. Drake
Chris Ochs wrote: I am pretty sure I know this already, but every time you run a Pl/Perl function it is just like running a perl script as far as having to load and compile the code right? My application runs under mod perl so I'm thinking that speed is not something I would gain by putting any o

Re: [GENERAL] Pl/Perl speed

2004-01-13 Thread Tom Lane
"Chris Ochs" <[EMAIL PROTECTED]> writes: > I am pretty sure I know this already, but every time you run a Pl/Perl > function it is just like running a perl script as far as having to load and > compile the code right? No, the perl script gets compiled only the first time the function is invoked (w

[GENERAL] Pl/Perl speed

2004-01-13 Thread Chris Ochs
I am pretty sure I know this already, but every time you run a Pl/Perl function it is just like running a perl script as far as having to load and compile the code right? My application runs under mod perl so I'm thinking that speed is not something I would gain by putting any of the code into the

Re: [GENERAL] pl/perl function life and variable scope - concurrency problem?

2003-11-12 Thread Doug McNaught
Christopher Murtagh <[EMAIL PROTECTED]> writes: > Thanks to a lot of help on this list, I've managed to get my pl/perl > function working. However, I have an unexpected result. Here's a simple > way to reproduce this problem: > > CREATE or REPLACE FUNCTION perltest(integer) > returns integer as

Re: [GENERAL] PL/Perl returning multiple rows

2003-11-11 Thread Christopher Murtagh
On Tue, 2003-11-11 at 00:07, Joe Conway wrote: > Write a Pl/Perl function that just does the syscall, and call it from > PL/pgSQL. Similarly for complex string parsing, etc. That would work if I could get the Pl/Perl function to return an array or set of results, but this brings me back to the o

Re: [GENERAL] PL/Perl returning multiple rows

2003-11-11 Thread Joe Conway
Alvaro Herrera wrote: Well, I wasn't the OP ;-). I thought Tcl had the capability, as it is sometimes said to be the most advanced PL. Nah, that would be PL/R ;-) Joe ---(end of broadcast)--- TIP 3: if posting/reading through Usenet, please send an

Re: [GENERAL] PL/Perl returning multiple rows

2003-11-11 Thread Joe Conway
Joe Conway wrote: Christopher Murtagh wrote: That would work if I could get the Pl/Perl function to return an array or set of results, but this brings me back to the original problem (unless I'm missing something obvious). Sorry, I guess I didn't sufficiently understand the issue. I don't reall

Re: [GENERAL] PL/Perl returning multiple rows

2003-11-10 Thread Joe Conway
Christopher Murtagh wrote: On Tue, 2003-11-11 at 00:07, Joe Conway wrote: Write a Pl/Perl function that just does the syscall, and call it from PL/pgSQL. Similarly for complex string parsing, etc. That would work if I could get the Pl/Perl function to return an array or set of results, but this b

Re: [GENERAL] PL/Perl returning multiple rows

2003-11-10 Thread Joshua D. Drake
Christopher Murtagh wrote: On Mon, 2003-11-10 at 23:05, Joshua D. Drake wrote: Hello, If you can code in Perl then pl/C wouldn't be a deep jump. That might not be a bad idea. Haven't done much C programming since my CS days, but I really loved it then. Other than here: http://www.pos

Re: [GENERAL] PL/Perl returning multiple rows

2003-11-10 Thread Joe Conway
Christopher Murtagh wrote: On Mon, 2003-11-10 at 21:11, Joshua D. Drake wrote: The fact that it is pl/pgSQL? Seriously though, I think that pl/pgSQL is counter intuitive to some people and those of us who are coming from say a Perl background are going to be much more proficient in using pl/Perl

Re: [GENERAL] PL/Perl returning multiple rows

2003-11-10 Thread Alvaro Herrera
On Mon, Nov 10, 2003 at 03:00:34PM -0800, Joshua D. Drake wrote: > >>Better start learning Tcl ... > What are we torturing people now? Can plPython do this? Well, aparently Tcl is not up to the task either, nor is plPython. At least I can find no mention on the docs nor the source code. Can yo

Re: [GENERAL] PL/Perl returning multiple rows

2003-11-10 Thread Christopher Murtagh
On Mon, 2003-11-10 at 23:05, Joshua D. Drake wrote: > Hello, > >If you can code in Perl then pl/C wouldn't be a deep jump. That might not be a bad idea. Haven't done much C programming since my CS days, but I really loved it then. Other than here: http://www.postgres.org/docs/7.3/static

Re: [GENERAL] PL/Perl returning multiple rows

2003-11-10 Thread Joe Conway
Christopher Murtagh wrote: On Mon, 2003-11-10 at 16:52, Alvaro Herrera wrote: Better start learning Tcl ... Thanks for the info. I'm ok with that, I like Perl, but I can live without it too. :-) Two questions: 1) Can Tcl return multiple rows? 3) ok, 3 questions... Any word on pl/php and a release

Re: [GENERAL] PL/Perl returning multiple rows

2003-11-10 Thread Joshua D. Drake
Hello, If you can code in Perl then pl/C wouldn't be a deep jump. J Christopher Murtagh wrote: On Mon, 2003-11-10 at 21:11, Joshua D. Drake wrote: The fact that it is pl/pgSQL? Seriously though, I think that pl/pgSQL is counter intuitive to some people and those of us who are coming from

  1   2   >