Closed john-guerra closed 3 years ago
Also, for me it has been very confusing what the SQLite object in a new notebook is. If I'm understanding correctly, it is just sql.js right?
Yes, as documented here: https://observablehq.com/@observablehq/recommended-libraries
BTW I cannot access SQLiteDatabaseClient from a notebook, right?
Not currently but I agree it would be nice to expose this functionality.
Loading sqlite databases from FileAttachments it is very convenient, but greatly limits the use of the library. It would be nice to easily load remote databases as @mbostock demonstrated in the original sqlite
I'm thinking something like
SQLiteDatabaseClient.open
that does:Also an
export
that does something likethis._db.export()
, and even better adownload()
that does the wholeDOM.download(async () => new Blob([await db._db.export()]), "mydb.db")
as I did in my export exampleAlso, for me it has been very confusing what the SQLite object in a new notebook is. If I'm understanding correctly, it is just sql.js right? It would be nice to have also a method of creating a new Database as in
new SQLite.Database()
but actually getting a database client object.BTW I cannot access SQLiteDatabaseClient from a notebook, right?