What is odd, is that I am using the prepare_v2 API.  The documentation says it 
should not happen but I am getting a return code 17.  I'm trying to debug this 
now... 

Can you open a database twice without closing it? And what problems might this 
condition cause?

Again in my log, I see the Opening of the DB twice with no Close.  

Thanks

________________________________
From: Roger Binns <rog...@rogerbinns.com>
To: sqlite-users@sqlite.org
Sent: Tuesday, October 4, 2011 10:38 PM
Subject: Re: [sqlite] How do you check if a sqlite database is open?

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 10/04/2011 10:35 PM, James Brison wrote:
> I am receiving a SCHEMA_ERROR, I believe this is happening because the Master 
> doesn't close it's connection before the Detail re-opens the db.

Huh? What would lead you to believe that?

In any event just the prepare_v2 API and you won't get schema errors.  If
you still want to use the old API then you handle schema errors by calling
prepare again.

Trying to second guess others opening or not opening the file would simply
lead to race conditions.

Roger
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)

iEYEARECAAYFAk6L7UsACgkQmOOfHg372QTezgCfczQ4UPBlFt4Eez/iOeZHu0D8
HO0Ani+GVaPiLf3Y8q5BtsMw5zdXm7hr
=YRCc
-----END PGP SIGNATURE-----
_______________________________________________
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