27 my $sth1 = $dbh->prepare ( $q1 ); 28 my $sth2 = $dbh->prepare ( $q2 ); 29 30 print "INFO: If we got this far, we were able to create two \ statement handles.\n"; 31 32 $sth1->execute or 33 die ( "FATAL: Unable to execute q1: " . $sth1->errstr ); 34 $sth2->execute or 35 die ( "FATAL: Unable to execute q2: " . $sth1->errstr ); #### INFO: If we got this far, we were able to create two statement handles. DBD::ODBC::st execute failed: [FreeTDS][SQL Server]Invalid cursor state (SQL-24000) at two_handles.pl line 34. FATAL: Unable to execute q2: [FreeTDS][SQL Server]Invalid cursor state (SQL-24000) at two_handles.pl line 34. Issuing rollback() due to DESTROY without explicit disconnect() of DBD::ODBC::db handle Driver=FreeTDS;ServerName=SqlServer;Database=FOOBAR at two_handles.pl line 34.