Re: [BUGS] Plperl trigger variables no longer global

2011-05-19 Thread Alvaro Herrera
Excerpts from Greg Sabino Mullane's message of mié may 18 12:03:00 -0400 2011: > On Mon, May 16, 2011 at 12:57:41PM -0600, Alex Hunsaker wrote: > > > Do we need to apply this patch? > ... > > My proposed fix is instead of declaring $_TD in > > Yes, please apply, I'm eager to continue testing 9.1 b

Re: [BUGS] Plperl trigger variables no longer global

2011-05-18 Thread Greg Sabino Mullane
On Mon, May 16, 2011 at 12:57:41PM -0600, Alex Hunsaker wrote: > > Do we need to apply this patch? ... > My proposed fix is instead of declaring $_TD in Yes, please apply, I'm eager to continue testing 9.1 but cannot proceed until something is in place. -- Greg Sabino Mullane g...@endpoint.com

Re: [BUGS] Plperl trigger variables no longer global

2011-05-16 Thread Alex Hunsaker
On Sun, May 15, 2011 at 14:02, Robert Haas wrote: >> Fixed in the attached plus added regression tests for both issues (use >> strict; && Global symbol "$_TD" requires explicit package name, test >> recursive trigger calls). Although Ill admit, given the point we are >> in the release I could see

Re: [BUGS] Plperl trigger variables no longer global

2011-05-15 Thread Robert Haas
On Thu, May 5, 2011 at 12:14 PM, Alex Hunsaker wrote: > On Thu, May 5, 2011 at 06:51, Alvaro Herrera > wrote: >> Excerpts from Alex Hunsaker's message of mié may 04 23:53:34 -0300 2011: >> >>> After playing with it a bit more I see 2 clear options: >>> 1) make $_TD global like %_SHARED. This sho

Re: [BUGS] Plperl trigger variables no longer global

2011-05-05 Thread Alex Hunsaker
On Thu, May 5, 2011 at 06:51, Alvaro Herrera wrote: > Excerpts from Alex Hunsaker's message of mié may 04 23:53:34 -0300 2011: > >> After playing with it a bit more I see 2 clear options: >> 1) make $_TD global like %_SHARED. This should not cause any problems >> as we make $_TD private via local(

Re: [BUGS] Plperl trigger variables no longer global

2011-05-05 Thread Alvaro Herrera
Excerpts from Alex Hunsaker's message of mié may 04 23:53:34 -0300 2011: > After playing with it a bit more I see 2 clear options: > 1) make $_TD global like %_SHARED. This should not cause any problems > as we make $_TD private via local() before each trigger call. Also pre > 9.1 non trigger func

Re: [BUGS] Plperl trigger variables no longer global

2011-05-04 Thread Alex Hunsaker
On Wed, May 4, 2011 at 16:20, Alex Hunsaker wrote: > > This seems to be broken by > http://git.postgresql.org/gitweb?p=postgresql.git;a=commit;h=ef19dc6d39dd2490ff61489da55d95d6941140bf > (Set up PLPerl trigger data using C code instead of Perl code.) > > Im not sure what the right fix is. Copying

Re: [BUGS] Plperl trigger variables no longer global

2011-05-04 Thread Alex Hunsaker
On Tue, May 3, 2011 at 17:40, Greg Sabino Mullane wrote: > This works in 9.0 but not in git/9.1 beta: > > CREATE FUNCTION wheredidmytdgo() > RETURNS TRIGGER > LANGUAGE plperlu > AS > $bc$ >    use strict; use warnings; >    my $new = $_TD->{new}; >    return; > $bc$; > > The error is: > > ERROR:  

[BUGS] Plperl trigger variables no longer global

2011-05-03 Thread Greg Sabino Mullane
This works in 9.0 but not in git/9.1 beta: CREATE FUNCTION wheredidmytdgo() RETURNS TRIGGER LANGUAGE plperlu AS $bc$ use strict; use warnings; my $new = $_TD->{new}; return; $bc$; The error is: ERROR: Global symbol "$_TD" requires explicit package name at line 3. CONTEXT: compilati