Hi all,

Any ideas on having 2 separate applications accessing the same WAL enabled
database?

Or does the first app get an entire lock? Can I perhaps set the THREAD mode
to help here?

I have tried:

                rc = sqlite3_exec(handle,"PRAGMA wal_checkpoint",0,0,0);
            rc = sqlite3_exec(handle,"PRAGMA synchronous=normal",0,0,0);
            rc = sqlite3_exec(handle,"PRAGMA temp_store=memory",0,0,0);

And obviously the following as well: "PRAGMA journal_mode=wal"

I have also tried "sqlite3_config(SQLITE_CONFIG_MULTITHREAD);"

Any ideas?

Thanks

Lynton

-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Lynton Grice
Sent: 14 November 2010 05:12 PM
To: 'General Discussion of SQLite Database'
Subject: [sqlite] WAL and multiple writers?
Importance: High

Hi there,

 

I have a "queue" implemented in C using SQLIte in WAL mode.

 

When I send messages to the queue....it is fine, and I can receive messages
from the queue no problem.

 

BUT when I try run BOTH applications at the same time the sender works 100%
and the receiver seems to be able to read the messages but not DELETE them
as they come in.

 

Am I doing something stupid here or is WAL not going to work for this Queue
implementation whereby I need two (or more) applications to be able to SEND
and RECEIVE at the same time?

 

Thanks for the help ;-)

 

Lynton

_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to