How about this?
sqlite3_stmt *sqlite3_next_stmt(sqlite3 *pDb, sqlite3_stmt *pStmt); This interface returns a pointer to the next prepared statement after pStmt associated with the database connection pDb. If pStmt is NULL then this interface returns a pointer to the first prepared statement associated with the database connection pDb. If no prepared statement satisfies the conditions of this routine, it returns NULL. The database connection pointer D in a call to sqlite3_next_stmt(D,S) must refer to an open database connection and in particular must not be a NULL pointer. -----Ursprüngliche Nachricht----- Von: Simon Slavin [mailto:slav...@bigfraud.org] Gesendet: Mittwoch, 02. Juli 2014 18:18 An: General Discussion of SQLite Database Betreff: Re: [sqlite] Problem with many connections On 2 Jul 2014, at 5:03pm, Grzegorz Sikorski <g.sikor...@kelvatek.com> wrote: > I admit I had missed this sentence, but to be honest, it seems to be very > confusing behaviour. I'm glad you have found the problem. It's not good and I don't think this is a good way to handle things. I hope SQLite4 changes this and if there are statements still open either returns an error code or automatically closes any open statements. Or both. It would also be nice if there was an API call you could make on a database handle which would return the number of statements which were open on that database. I have no idea what to do about open transactions if their database connection is closed. Simon. _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users ----------------------------------------------------------------------- Gunter Hick Software Engineer Scientific Games International GmbH Klitschgasse 2 – 4, A - 1130 Vienna, Austria FN 157284 a, HG Wien Tel: +43 1 80100 0 E-Mail: h...@scigames.at This e-mail is confidential and may well also be legally privileged. If you have received it in error, you are on notice as to its status and accordingly please notify us immediately by reply e-mail and then delete this message from your system. Please do not copy it or use it for any purposes, or disclose its contents to any person as to do so could be a breach of confidence. Thank you for your cooperation. _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users