sqlite3 close返回错误代码5

前端之家收集整理的这篇文章主要介绍了sqlite3 close返回错误代码5前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
在使用sqlite3_close函数关闭sqlite3时,它返回错误代码5
5 – 数据库文件正忙.如何解决这个问题.

解决方法

sqlite3_close documenation清楚地说明了这一点:

Applications must finalize all prepared statements and close all BLOB handles associated with the sqlite3 object prior to attempting to close the object. If sqlite3_close() is called on a database connection that still has outstanding prepared statements or BLOB handles,then it returns sqlITE_BUSY.

猜你在找的Sqlite相关文章