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

Add --alter option to insert command #23

Closed
simonw opened this issue Feb 27, 2024 · 2 comments
Closed

Add --alter option to insert command #23

simonw opened this issue Feb 27, 2024 · 2 comments
Labels
enhancement New feature or request

Comments

@simonw
Copy link
Owner

simonw commented Feb 27, 2024

To tell Datasette to alter tables to add any missing columns. Requires 1.0a9 or higher: https://docs.datasette.io/en/latest/changelog.html#a9-2024-02-16

@simonw simonw added the enhancement New feature or request label Feb 27, 2024
@simonw
Copy link
Owner Author

simonw commented Feb 28, 2024

Without alter-table:

echo '{"foo": "bar", "baz": 1}' | dclient insert staff test_alter --create - --json --alter

Error: Permission denied: need alter-table

CleanShot 2024-02-27 at 20 22 55@2x

Then with a new token with that permission enabled... it worked!

@simonw simonw closed this as completed in adfa6cc Feb 28, 2024
simonw added a commit that referenced this issue Feb 28, 2024
@simonw
Copy link
Owner Author

simonw commented Feb 28, 2024

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

No branches or pull requests

1 participant