SQLite has 5 different locking levels - http://www.sqlite.org/lockingv3.html : unlocked, shared, reserved, pending, exclusive. An important lock for this issue is Shared lock:
"SHARED - A database can be read but not written. Processes can hold SHARED locks at the same time, so there can be many simultaneous readers. But no other thread or process is allowed to write to the database file when one or more SHARED locks is active." .
Locks are the level of the table (therefore, doing something with one row in the database - the whole table is locked).
, , .
: UNLOCKED → PENDING → SHARED → UNLOCKED ( ). , , -, - , .
- , , . autocommit /:
UNLOCKED → PENDING → SHARED → RESERVED → PENDING → EXCLUSIVE → UNLOCKED.
Exclusive, () . EXCLUSIVE. SQLite , PENDING . .
, - , , , . , . SQLite ACID, , , , .
- " SQLite", "".