Closed chekos closed 4 years ago
Maybe add another button after Format SQL and Run SQL
https://github.com/simonw/datasette/blob/master/datasette/templates/query.html
essetially
and just use encodeURIcomponent() on the query to add to the body parameter
maybe encode back ticks too `
select #sql-query -> encode it -> send it as body
on load create the URL and attach it as href of button to submit query
because it's jinja2 I think you can just access the request object and grab the SQL query URI ready to go
{{ request.spit("sql=")[0].split("&")[0] }}
maybe
maybe it's {{request.args.get("sql")}}
Is there a way to send the SQL query we just ran as the text of a new GitHub issue? It would make submitting canned queries a lot easier 🤔