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

Question: JSONiq to SQL #1259

Open
jsommr opened this issue Sep 3, 2024 · 2 comments
Open

Question: JSONiq to SQL #1259

jsommr opened this issue Sep 3, 2024 · 2 comments
Labels

Comments

@jsommr
Copy link

jsommr commented Sep 3, 2024

I keep coming back to JSONiq because it's such an elegant language, and it would be cool if I could use it for an api instead of eg. GraphQL. There's Hasura and similar for the latter that auto generates a GraphQL api for a database and uses the GraphQL AST to generate a single SQL query for a database (simply put).

Would it make sense (and be possible) for RumbleDB to act as an api, turning a JSONiq POST request into SQL, query a database (efficiently, with as much sql packed into one query as possible) and return the result? I don't know enough about Spark, but ClickHouse has a Spark connector. Would it be possible to connect RumbleDB with that (or similar for other db's) and get pushed down requests (including aggregates like avg, sum etc.)?

@ghislainfourny
Copy link
Member

Thank you for your feedback @jsommr! Apologies as I only saw it now.

Generally, it does make a lot of sense to allow RumbleDB to connect to other backends. If that backend has a Spark connector, then it should be even relatively easy. I tried for example with MongoDB (which also has a Spark connector) and it was only an afternoon of work to connect it.

Regarding pushdowns: absolutely, this is even desirable. Typically, one builds a first prototype that just generally connects to the backend, and then one keeps adding pushdowns and optimizations to make it faster.

Thank you for the nice words on JSONiq!

@jsommr
Copy link
Author

jsommr commented Sep 30, 2024

Could you publish your mongodb experiment somewhere? Then I could use that as a reference

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

No branches or pull requests

2 participants