go-llsqlite / crawshaw

Low-level Go interface to SQLite 3 using cgo
ISC License
12 stars 5 forks source link

Support for VFS #2

Open tionis opened 9 months ago

tionis commented 9 months ago

There is https://github.com/psanford/sqlite3vfs, but I don't know if that can work with crawshaw as I think that it uses *sql.DB

tionis commented 9 months ago

Would be nice to have one library to handle all things sqlite

anacrolix commented 9 months ago

Yeah it is a shame. The crawshaw approach has kind of pushed itself into a corner, there are some oddities in the API that make interoperating with other sqlite3 libraries not very useful.

FWIW the adapter repo in this org provides a way to switch between crawshaw and zombiezen (pure Go) implementations of sqlite3.

I was able to get some interoperability with the riyaz-ali sqlite3 extension support by exposing access to the underlying C sqlite3 * object, you might be able to do something similar.