On 27 Jun 2016, at 3:53pm, mon siong <monsi...@yahoo.com> wrote: > I intend to do error log callback . I want to terminate my program when an > operation could potentially cause my DB to corrupt to identify which code > actually cause this . > > Which Result code that i need to capture
All API calls should return SQLITE_OK except for sqlite_step() which can return SQLITE_ROW or SQLITE_DONE too. Any other code indicates a fault and your program when it sees them, before more harm is done. > which could potentially cause my DB to corrupt ? There are no SQLite calls which can corrupt your database. Trapping result codes will not tell you which call caused database corruption. It will only tell you that the database is already corrupt. It is rare for any call to SQLite to cause database corruption. Almost all causes of database corruption are either A) faults in your program outside SQLite calls, for example part of your program overwriting memory that SQLite was using B) faulty hardware Simon. _______________________________________________ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users