In my C# project, I'm using System.Data.SQLite.dll
downloaded from CodeProject.
My problem is as per the title - how to get the error codes after calling SqliteCommand.ExecuteNonQuery()
function?
Error codes such as SQLITE_CONSTRAINT, SQLITE_BUSY, SQLITE_LOCKED
as shown here.
I'm going to add to this to help others, if you're developing in .NET. Use the
SQLiteErrorCode
enumeration to test the result, cast the ErrorCode:use the Exception.StackTrace or the SQLiteException.ErrorCode
Good question. System.Exception does not have a member by the name ".ErrorCode"