Search code examples
csqlitesql-deleterows-affected

Getting the number of affected rows for a SQLite statement using the C API


I'm executing a DELETE statement using the SQLite 3 C API, and I'd like to know how to fetch the number of affected rows.

Unfortunately, there is no function such as sqlite3_affected_rows or similar.


Solution

  • Try sqlite3_changes() and/or sqlite3_total_changes()