> I do a transaction on connection 1 using BEGIN IMMEDIATE, some rows updated,
> COMMIT.
> Then, when I attempt same sequence on connection 2, when I do first call to 
> step
> to execute begin transaction and it never returns.

Do you check result code from COMMIT and is it successful? My guess is
you have some SELECT statements which are not reset or finalized
before COMMIT. And your COMMIT in such situation should return
SQLITE_BUSY. If that's true then second BEGIN IMMEDIATE just can't
finish because another writing transaction is not finished yet.


Pavel

On Sun, Feb 13, 2011 at 6:04 PM, jeff archer <jarch...@yahoo.com> wrote:
> I thought this would be OK but now that I am seeing it fail I am having my
> doubts.
>
>
> I have created 2 db connections on the same thread, both on the same file.  
> i.e.
> 2 calls to sqlite3_open16() (use exact same filename both times) have created 
> 2
> sqlite3 instances.  I do this because I have 2 classes which each have their 
> own
> set of tables in this single db file.  I thought it would be OK because I do 
> not
> intemix operations on the 2 connections.
>
> I do a transaction on connection 1 using BEGIN IMMEDIATE, some rows updated,
> COMMIT.
> Then, when I attempt same sequence on connection 2, when I do first call to 
> step
> to execute begin transaction and it never returns.
>
>  Jeff Archer
> Nanotronics Imaging
> jsarc...@nanotronicsimaging.com
> <330>819.4615
> _______________________________________________
> sqlite-users mailing list
> sqlite-users@sqlite.org
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to