This is almost ceratinly a perl problem that has nothing to do with postgres.
Please construct a small test case - I at least don't have time to spend wading through huge gobs of code. Note: if the variable is referred to by a live subroutine it will still be alive. See man perlref and search for "closure" - it might help you. cheers andrew David Fetter wrote: > Folks, > > While testing DBI-Link, I've noticed something very odd. In the > trigger code, I have subroutines with 'my' variables in them, which I > thought meant that as soon as the subroutine returned, the variables > went away. > > They are not going away :( > > Please find attached some sample output along with DBI-Link. The > database I'm connecting to is MySQL's Sakila, but the same happens in > Oracle, so I don't think (this time ;) it's a MySQL problem. > > If I quit the session or reload the functions, the ghost variables go > away, but I can't ask people to do that between queries. > > Help! > ---------------------------(end of broadcast)--------------------------- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match