Xuanvinh Vu <[EMAIL PROTECTED]> wrote: > I did check and I have all the BEGINs and COMMITs. I understand that > by default the sqlite busy signal is given right away so what I do is > I wait till the next interval elapses to try to update the DB again > by that time whatever the transaction that causes the DB to block me > before should have been completed.
Wouldn't you have a livelock situation? If you have a transaction that executes every 10 seconds and another that executes every 5 minutes, then it's possible that every time 5-minute transaction tries to run a 10-second transaction happens to run also. There is an even number of 10-sec intervals in 5 minutes. You need some sort of back-off scheme to de-synchronize the two threads that started to run in lockstep. http://en.wikipedia.org/wiki/Deadlock#Livelock Igor Tandetnik _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users