ok thanks for your advice. If I use separate connections for the reading threads then is there an advantage to using "shared cache" for those connections?
On 19 January 2018 at 16:35, Simon Slavin <slav...@bigfraud.org> wrote: > On 19 Jan 2018, at 4:26pm, Hannah Massey <hannah.bea...@gmail.com> wrote: > > > Will #pragma uncommitted work in WAL mode and will it have the effect I'm > > looking for (where the read will be faster because it can ignore the > > recently written information in the WAL File) and simply use the database > > file only? > > The command you’re talking about is > > PRAGMA read_uncommitted = boolean > > You may find you don’t need it. Switch to WAL mode and try it without > that PRAGMA. It works more or less the way you described: one connection > can write while other read, and nothing will block anything else. > > Pay a lot of attention to how many connections you’re using. You might > want one connection for the writing, and another for all the reading > threads. Or you might want separate connections for the reading threads > too. Testing various approaches will let you find the solution which best > suits your programming and timing requirements. > > Simon. > _______________________________________________ > sqlite-users mailing list > sqlite-users@mailinglists.sqlite.org > http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users > _______________________________________________ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users