in reply to CGI::Session disconnect invalidates 1 active statement handle

my $conexion = DBI->connect($source, $user, $passwd, {'RaiseError' => 1}); $query = $conexion->prepare("SELECT * FROM table"); $query->execute(); $resultado = $query->fetchrow_hashref(); $query->finish (); $conexion->disconnect ();
  • Comment on Re: CGI::Session disconnect invalidates 1 active statement handle

Replies are listed 'Best First'.
Re^2: CGI::Session disconnect invalidates 1 active statement handle
by Anonymous Monk on Apr 29, 2011 at 07:45 UTC
    The best answer is in the previous post than mine, I'd only explain it: You need to call this piece of code $query->finish (); atripathi at ea dot com
      $query->finish (); is the answer, thx guys.