On 30 Jun 2014, at 7:47pm, Eric Rubin-Smith <[email protected]> wrote:
> I am a big fan generally of the clarity of the sqlite docs. But this page > could use another section detailing all the possible result codes' specific > semantics under sqlite3_step(), and in particular what the client should do > in those circumstances. I agree with this, and want to extend it to other calls. Many of the API calls could usefully do with an explanation of non _OK results, what they mean, and how a typical app might react to them (including other sqlite3_ calls that might be used). I have tried three times to explain the combinations of things that might lead to ROLLBACK, which calls to use, and how to react to failure of the ROLLBACK command. I failed, because I lack detailed understanding of what might cause ROLLBACK to fail and what it's still safe to try. There's also an unfortunate consequence of SQLite trying to be helpful. In strict SQL the programmer has to issue BEGIN before any operation and ROLLBACK or END after it. So if you issue ROLLBACK the SQL engine can safely ignore anything until it sees another BEGIN. But SQLite automatically wraps individual operations in transactions. So it can see another command before the END and it has to do it. Which can be nasty. Simon. _______________________________________________ sqlite-users mailing list [email protected] http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

