Replies: 1 comment
-
Some other comments:
Like Andy says, it is less common to go from plan back to SQL -- however, DataFusion does have the ability to generate https://substrait.io/ plans, which is a developing standard for a lower level relational algebra represenation
There is Rust vs Java difference, as @andygrove says. The other major difference that I know of is that Calcite focuses on the planning /frontend aspect but doesn't have an actual execution engine (so it doesn't execute plans directly). If you do more research and find out more that would be great Good luck with the project. It sounds interesting! |
Beta Was this translation helpful? Give feedback.
-
I asked @andygrove a set of questions related to using Arrow Data Fusion and other tools to build a high level query language compiler to SQL for an ORM. His answers might be of interest to the rest of the community, which additionally might want to chime in with insight. The idea is to follow the conversation in here rather than privately
I've been thinking about creating a query compiler that can convert complex queries written in a high-level language like Prisma's representation into optimized SQL for different databases. I found Calcite quite interesting because it reuses relational algebra and optimization passes, and it supports various database backends through adapters like JDBC.
Then, I came across Apache Arrow DataFusion, which seems like an evolution over Calcite. However, it appears to focus more on building query engines for tabular format files rather than serving as front-ends for existing databases, like Calcite's JDBC adapter does.
In a later email, I told Andy that I found https://prql-lang.org, a higher level language that compiles to SQL and has a lot of overlapping with the initial query compiler I had in mind. He will refer to it below
I have a few clarifying questions: (answers inline as quotes)
Following up the conversation in here so it's open to everyone. Thank you @andygrove! 🙇♂️
Beta Was this translation helpful? Give feedback.
All reactions