Re: [BUGS] Plperl functions not re-entrant, wrong results

2007-04-30 Thread David Fetter
On Mon, Apr 30, 2007 at 12:12:11PM -0400, Kenneth Downs wrote: > Tom Lane wrote: > >Kenneth Downs <[EMAIL PROTECTED]> writes: > > > >>Here is a test case to show that plperl functions are not re-entrant. > >> > > > >I'm very bad in perl, but I think you need to declare all your variables > >w

Re: [BUGS] Plperl functions not re-entrant, wrong results

2007-04-30 Thread Kenneth Downs
Tom Lane wrote: Kenneth Downs <[EMAIL PROTECTED]> writes: Here is a test case to show that plperl functions are not re-entrant. I'm very bad in perl, but I think you need to declare all your variables with "my" to make them local instead of global. regards, tom

Re: [BUGS] Plperl functions not re-entrant, wrong results

2007-04-30 Thread Tom Lane
Kenneth Downs <[EMAIL PROTECTED]> writes: > Here is a test case to show that plperl functions are not re-entrant. I'm very bad in perl, but I think you need to declare all your variables with "my" to make them local instead of global. regards, tom lane ---

[BUGS] Plperl functions not re-entrant, wrong results

2007-04-30 Thread Kenneth Downs
Here is a test case to show that plperl functions are not re-entrant. Level_one: one row Level_two: one row Level_thr: one row The idea is that an AFTER STATEMENT UPDATE trigger on Level_thr calls a plperl routine. The plperl routine has a hardcoded 3-pass loop that updates table Level_two.

[BUGS] Plperl functions not re-entrant, wrong results

2007-04-30 Thread Kenneth Downs
Here is a test case to show that plperl functions are not re-entrant. Level_one: one row Level_two: one row Level_thr: one row The idea is that an AFTER STATEMENT UPDATE trigger on Level_thr calls a plperl routine. The plperl routine has a hardcoded 3-pass loop that updates table Level_two.