>From the docu of sqlite3_finalize:
 "The application must finalize every prepared statement [1] in order
to avoid resource leaks."
 Ok, fine. But the given reason(s) seem not to be complete. After
preparing and executing the SQL command "PRAGMA page_size;" without
finalizing the prepared statement, all tables seem to be locked (at
least any "DROP TABLE"-command fails). See the attached code-sample
for reproducing this behaviour (in the second call of testSQLt3 with
callFinalize=false).
 When running into this problem I was looking into the wrong
direction for some time ...
 The code also demonstrates a second "inaccuracy" that has cost me
some time: when sqlite3_step returns with SQLITE_ROW, sqlite3_errmsg
gives "unknown error" instead of something like "row available (no
error)".
 SQLite is a great piece of software. Maybe these hints help others
to be even more effective with SQLite.
 Thank you for reading,
 Wolfgang
  

Links:
------
[1] http://www.sqlite.org/c3ref/stmt.html
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to