On 30 Jul 2019, at 6:44pm, test user <example.com.use...@gmail.com> wrote:

> I am using `journal_mode=WAL`.
> 
> What I am trying to do:
> 
> From the first `BEGIN` that returns `SQLITE_OK`, all SELECTs read from the 
> same snapshot/point in time.

This is the effect if you use BEGIN IMMEDIATE instead of just BEGIN.  So do 
BEGIN IMMEDIATE, then as many SELECTs as you want, then END.  For the duration 
of that transaction, all your SELECTs will reflect the same snapshot of the 
database.

> The issue is that its hard to tell if I reading from a read snapshot (where 
> any successful commit on other connections since the reads BEGIN are ignored).

Depending on various things, other connections trying to change the database 
will be blocked (locked out of making changes), or will make changes that will 
not be 'seen' by the above transaction.
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to