On 6/25/2013 10:13 PM, Woody Wu wrote:
1. When a exclusive transation started and not yet commit, I found if I
open another connection to the same database and try to access it (using
sqlite3_step), I got the error code SQLITE_MISUSE.  It sounds a little
strange because I thought the error code should be SQLITE_BUSY.  Is that
normal?

You are doing something wrong. Some call failed and you are passing an invalid handle to a subsequent call, or something like that. That is what causes SQLITE_MISUSE: the existence of an exclusive transaction is perhaps the proximate cause of the original failure, but it's not the direct cause of SQLITE_MISUSE.

2. After started a exclusive transaction with success. Can I expect that
all the operations that follows should run with success?

Yes, barring catastrophic failure (e.g. hard drive gone bad) and programming errors on your part (e.g. trying to prepare a syntactically incorrect statement).

Especially, is that possible that the 'commit' could get an error of 
SQLITE_BUSY?

No, it is not.
--
Igor Tandetnik

_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to