> When you have a connection with multiple attached databases and the
> connection acquires an exclusive lock, does it always lock all attached
> databases or does it keep track of which databases require the lock? 

1st process:
C:\Documents and Settings\Administrator\Pulpit>sqlite3.exe a.db
SQLite version 3.3.17
Enter ".help" for instructions
sqlite> attach 'b.db' as b;
sqlite> begin exclusive;

2nd:
C:\Documents and Settings\Administrator\Pulpit>sqlite3.exe b.db
SQLite version 3.3.17
Enter ".help" for instructions
sqlite> create table tab(col);
SQL error: database is locked

So it locks all attached databases.


> Does
> using separate databases and attaching them improve concurrency (by
> providing finer-grained locking)?

Yes it does. You can open a connection to a memory database, store each table 
in a separate database and attach  them if needed. I'v already changed 
sqlite to do it transparently. It still has a lot of bugs, but it has 
already proven to work. But if you don't mind attaching databases manually 
originall sqlite will work perfectly. 


----------------------------------------------------------------------
Czy nadajesz sie na (p)osla?
>>> http://link.interia.pl/f1a86


-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------

Reply via email to