Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Local database feature #13

Open
Cretezy opened this issue Nov 7, 2023 · 0 comments
Open

Local database feature #13

Cretezy opened this issue Nov 7, 2023 · 0 comments

Comments

@Cretezy
Copy link

Cretezy commented Nov 7, 2023

Would be great to also be able to access local databases when using Wrangler.

Wrangler stores its local SQLite database at sqlite3 .wrangler/state/v3/d1/miniflare-D1DatabaseObject/ab43d37f48135ef454cdb4895268c4c8817c5f76a0ae8db115f478b15ca263a5.sqlite.

When starting d1-console with --local or -l, it should connect to the local database instead (no need for API keys). Most of the implementation would be in queryDatabase or queryDatabaseApi), where instead of fetch you would access the local SQLite database using https://www.npmjs.com/package/better-sqlite3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant