title: "Database is locked" error in SQLite3 with Qt
body: <p>I'm using SQLite3 on an embedded system and on x86 in a Qt application. I'm experiencing the common error "Database is locked" when multiple threads try to read/write the database.</p>
  
  <p>I read <a href="http://www.sqlite.org/cvstrac/wiki?p=DatabaseIsLocked" rel="nofollow">this</a> article suggested in some other answers, but I'm creating a different connection for each thread.</p>
  
  <p>By adjusting a bit the QSQLITE_BUSY_TIMEOUT option (to a very large value: 10000000) I solved this problem on the x86 system and on the embedded system, but in the latter case only when not using transactions. Unfortunately I need to use transactions for all the work of each thread.</p>
  
  <p>My question is: isn't it supported by SQLite3 to read/write from/to the database concurrently when using transactions? Why doesn't it simply wait all the necessary time to acquire the lock? Maybe I haven't set it up correctly?</p>