笔者在使用python 处理一sqlite3文件时,出现以下错误:
sqlite3.DatabaseError: file is encrypted or is not a database
使用的sqlite文件路径是没有问题的,在:
http://stackoverflow.com/questions/11456623/using-an-sqlite3-database-with-wal-enabled-python
找到了答案,原因是这个sqlite开启了WAL。解决方法是:
I just downloaded the latest version of sqlite from
http://www.sqlite.org/download.html and overwrote the old .dll
in my python27/DLL directory.
下载最新版本的sqlite dll文件覆盖python自带的dll文件(\Python27\DLLs)。