Subject: | Incorrect return value from do() |
Perl v5.6.1, running on a Debian linux machine using my own compile of DBD::SQLite.
Anyway, for INSERT or DELETE statements, the return value from do() is supposed to be the number of rows affected (that's what the DBI man page says), or -1 if it can't be determined.
However, DBD::SQLite seems to return "0E0" regardless of what happened. (Unless there's an error - then the return value seems bizarre)
The easiest way to reproduce this is to change line 109 of t/30insertfetch.t from:
Test($state or $dbh->do("DELETE FROM $table WHERE id = 1"), 'delete')
to:
Test($state or (1 == $dbh->do("DELETE FROM $table WHERE id = 1")), 'delete')