Read an SQLite 2 database using Python 3
Question: I have an old SQLite 2 database that I would like to read using Python 3 (on
Windows). Unfortunately, it seems that Python's sqlite3 library does not
support SQLite 2 databases. Is there any other convenient way to read this
type of database in Python 3? Should I perhaps compile an older version of
pysqlite? Will such a version be compatible with Python 3?


Answer: As the pysqlite author I am pretty sure nobody has ported pysqlite 1.x to
Python 3 yet. The only solution that makes sense effort-wise is the one
theomega suggested.

If all you need is access the data from Python for importing them elsewhere,
but doing the sqlite2 dump/sqlite3 restore dance is not possible, there is an
option, but it is not convenient: Use the builtin ctypes module to access the
necessary functions from the SQLite 2 DLL. You would then implement a minimal
version of pysqlite yourself that only wraps what you really need.

