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

Allow streaming rows from /v1/transactions requests #51

Open
jeromegn opened this issue Sep 18, 2023 · 0 comments
Open

Allow streaming rows from /v1/transactions requests #51

jeromegn opened this issue Sep 18, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@jeromegn
Copy link
Member

jeromegn commented Sep 18, 2023

In SQLite, it's possible to return data as part of an INSERT or UPDATE. It could also make sense to use a transaction for reading data only (if you want to do multiple SELECT, for example).

Right now, the /v1/transactions API handler does not stream back results and in fact only accepts statements that won't return data.

It would be desirable to mimic using a plain SQLite database as much as possible via the HTTP API.

There are some challenges:

  • Should it be possible to stream rows back for multi-statement transactions? Perhaps we only stream the last one or only allow 1 statement.
  • Come up with a new type of NDJSON-serialize line for "rows affected"
  • Make it backwards compatible (should be doable via Accept header?)
@jeromegn jeromegn added the enhancement New feature or request label Sep 18, 2023
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