sybperl-l Archive
Up Prev Next
From: "Humphrey Widjaja" <h4w301 at gmail dot com>
Subject: DBD-Sybase: BULK-Load and "disconnect invalidates 1 active statement handle"
Date: Aug 26 2006 3:55PM
Hi All,
I'm using Bulk-Load in DBD::Sybase. When I run:
$dbh->commit;
$sth->finish;
$dbh->disconnect;
I got a warning message "disconnect invalidates 1 active statement handle".
It's gone when I change it to:
$dbh->commit;
$sth->finish while ($sth->{Active});
$dbh->disconnect;
Why do I need to run "$sth->finish()" two times after "$dbh->commit()"?
Is my code okay to run finish() while it's active?
Regards,
Humphrey Widjaja
ps:
- I know DBI::finish is not strictly required
- The sample code in DBD::Sybase manual is also giving same error
- I use DBI v1.52 and DBD::Sybase v1.07
|