in reply to Re^7: Can I get the actual error for DBI->execute() ?
in thread Can I get the actual error for DBI->execute() ?

Marshall write: I don't know if DBI returns 1 or 0E0 for a successful SELECT operation.

Assuming there wasn't an error, from perldoc DBI: "If the number of rows affected is not known, then "execute" returns -1."

  • Comment on Re^8: Can I get the actual error for DBI->execute() ?

Replies are listed 'Best First'.
Re^9: Can I get the actual error for DBI->execute() ?
by Marshall (Canon) on Jun 24, 2024 at 18:05 UTC
    Cute. So,
    undef: sql command didn't work
    0E0: sql command worked and returned zero rows
    >0: sql command worked and returned indicated number of rows
    -1: sql command worked but number of rows is unknown (e.g. select)