I believe at least when you use
sqlite3_prepare_v2/sqlite3_step/sqlite3_finalize yourself and set
busy_timeout to 0 you will get SQLITE_BUSY every time you try to call
sqlite3_step and database is locked. So after receiving this return
code you can do whatever you want, even queue your statements
I'm writing an application that uses an SQLite DB to maintain a list of
hashes that mutliple threads access at random times. Is there a way to
queue sqlite3_exec() statements to locked databases or a way to check if
a database is locked so I can retry every few seconds?
Thanks,
Kurt
2 matches
Mail list logo