[Sun Nov 15 02:59:17 2009] [error] [client 0.0.0.1] DBI::db=HASH(0xc40d5a0)->disconnect invalidates 2 active statement handles (either destroy statement handles or call finish on them before disconnecting) at /usr/lib/perl5/site_perl/5.8.8/Apache/Session/Lock/MySQL.pm line 90. [Sun Nov 15 02:59:20 2009] [error] [client 0.0.0.1] DBI::db=HASH(0xb1adef0)->disconnect invalidates 2 active statement handles (either destroy statement handles or call finish on them before disconnecting) at /usr/lib/perl5/site_perl/5.8.8/Apache/Session/Lock/MySQL.pm line 90. #### $sth = $dbh->prepare(qq{select * from `table`}); $sth->execute(); my $_var = $sth->fetchrow_hashref(); $sth->finish(); #<--- like this here... #### my $_var = $dbh->selectrow_array(qq{select `column` from `table` where `something` = ?}, undef, "somethingelse"); # Done getting $_var no database connection right, to close right? #### if($sess_ref) { $sess_ref->close(); # If there is a session open, close it } if($dbh) { $dbh->disconnect(); } print end_html(); #### sub close { my $self = shift; untie (%{$self}); }