- Notifications
You must be signed in to change notification settings - Fork 1k
feat: add R2 SQL command #10558
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
Merged
Merged
feat: add R2 SQL command #10558
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
🦋 Changeset detectedLatest commit: b368fe6 The changes in this PR will be included in the next version bump. This PR includes changesets to release 3 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
create-cloudflare
@cloudflare/kv-asset-handler
miniflare
@cloudflare/pages-shared
@cloudflare/unenv-preset
@cloudflare/vite-plugin
@cloudflare/vitest-pool-workers
@cloudflare/workers-editor-shared
wrangler
commit: |
5495b00 to ea5d367 Compare edmundhung reviewed Sep 8, 2025
edmundhung reviewed Sep 8, 2025
| @laplab please update PR description with a brief intro about CLOUDFLARE_R2_SQL_TOKEN env variable. |
penalosa reviewed Sep 9, 2025
fe48a3c to 67dc2fa Compare penalosa reviewed Sep 9, 2025
fa4bf40 to a9fec20 Compare sejoker approved these changes Sep 10, 2025
penalosa reviewed Sep 10, 2025
penalosa reviewed Sep 10, 2025
Co-authored-by: Somhairle MacLeòid <smacleod@cloudflare.com>
54b4f94 to b368fe6 Compare penalosa approved these changes Sep 11, 2025
Merged
5 tasks
emily-shen pushed a commit that referenced this pull request Sep 12, 2025
* feat: r2 sql commands * fix: format results, fix bugs * fix: renames * fix: add tests * fix: use common framework for the token env variable * fix: add changeset * fix: snapshots * fix: formatting * fix: review * fix: replace UserError with APIError where appropriate * feat: add spinner while waiting for query result * fix: tests * fix: remove enable/disable commands * fix: update query url * fix: refactor Co-authored-by: Somhairle MacLeòid <smacleod@cloudflare.com> * fix: docs link and refactor * fix: style * fix: tests * fix: lint --------- Co-authored-by: Somhairle MacLeòid <smacleod@cloudflare.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Add this suggestion to a batch that can be applied as a single commit. This suggestion is invalid because no changes were made to the code. Suggestions cannot be applied while the pull request is closed. Suggestions cannot be applied while viewing a subset of changes. Only one suggestion per line can be applied in a batch. Add this suggestion to a batch that can be applied as a single commit. Applying suggestions on deleted lines is not supported. You must change the existing code in this line in order to create a valid suggestion. Outdated suggestions cannot be applied. This suggestion has been applied or marked resolved. Suggestions cannot be applied from pending reviews. Suggestions cannot be applied on multi-line comments. Suggestions cannot be applied while the pull request is queued to merge. Suggestion cannot be applied right now. Please check back later.
Fixes https://jira.cfdata.org/browse/KRB-49.
This change adds one command:
wrangler r2 sql query- send an SQL query targeting an R2 Data Catalog.This command relies on
CLOUDFLARE_API_TOKENenv variable to provide an API token. For now, a separate token with specific permissions is required to connect to the R2 SQL service.