Thanks a lot Simon. Now I understand a little bit better. Last question: (hopefully :-) )
Takes your suggestion with PDO setAttribute(PDO:: ATTR_TIMEOUT, the same effect as Richards with PRAGMA busy_timeout? For example I do a: $dbConnection =$db->query('PRAGMA busy_timeout=60000') ; instead of $dbConnection->setAttribute(PDO:: ATTR_TIMEOUT, 60); is this the same? Werner 2016-01-14 16:00 GMT+01:00 Simon Slavin <slavins at bigfraud.org>: > > On 14 Jan 2016, at 1:42pm, Werner Kleiner <sqlitetester at gmail.com> wrote: > > > The windows application is written in C# and uses the > sqlite.systemData.dll. > > I'm sure someone here can tell you how to set a timeout in that. > > > What does the timeout mean in detail for sqlite ? > > Is this time (in your example 5 minutes) for each SQL query which is > > executed? > > SQLite contains its own backoff-and-retry procedure for use when the > database is locked. By default the timeout value is 0 which means SQLite > never gets to use it. But instead you can set a timout value. > > Then if SQLite tries the command and finds that the database is locked it > will sleep a while, try again, sleep a little longer, try again, sleep even > longer, try again ... and it will keep doing this until the timeout value > has been reached. Only if it is still failing at that time will SQLite > return SQLITE_BUSY or SQLITE_LOCKED. At that point the error is final, and > there's no need to implement your own system for backoff-and-retry. > > Simon. > _______________________________________________ > sqlite-users mailing list > sqlite-users at mailinglists.sqlite.org > http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users >