Comments (4)
Thanks @alamb ! Can I ask a follow-up — we are trying to go the other direction — i.e. construct SQL queries from an AST (rather than parsing SQL) — do you think sqlparser is a good fit for that?
Yes I think it is a good fit
Does running Display for a sqlparser AST make a SQL query? It looks like it does, which would be awesome...
As long as the AST is an actual query then yes :) In fact many of the tests in sqlparser verify that parsing a sql string, and then Display
ing it produces the original SQL string
from prql.
That's great news! Thanks!
from prql.
👋 hi @max-sixty -- I (biasedly) think sqlparser is high quality and fairly stable and likely to incrementally add support for new SQL features from the community
I think many projects use sqlparser successfully, both directly like datafusion as well as fork sqlparser for their own use internally and occasionally contribute patches back upstream. The license is the liberal Apache license.
The maintainers only have limited time to work on the project however, so changes in the core repo will likely remain on rounding out the SQL parsing support
from prql.
Thanks @alamb ! Can I ask a follow-up — we are trying to go the other direction — i.e. construct SQL queries from an AST (rather than parsing SQL) — do you think sqlparser is a good fit for that? Does running Display
for a sqlparser AST make a SQL query? It looks like it does, which would be awesome...
from prql.
Related Issues (20)
- Nightly tests failed
- Parentheses omitted from sql output in non-commutative operations HOT 8
- Nightly tests failed HOT 1
- Name of the type for UTF-8 encoded strings of textual data HOT 4
- Top with group on Postgres HOT 5
- `std.prql` module HOT 2
- Modules containing data (tables, relations) HOT 3
- Release plan for 0.11.1 HOT 2
- Nightly tests failed HOT 1
- Remove `std.prql_version` in favor of `std.prql.version` HOT 5
- Nightly tests failed HOT 4
- Grouping breaks `select * except` HOT 2
- Set up text "fixture" for CLI project tests
- Clickhouse DATETIME conversion invalid format HOT 4
- Zig tests started failing HOT 3
- The various exit status codes from `prqlc` HOT 2
- Python compiler needs a flag to return the full sequence of errors as json HOT 5
- Compiler panic with `sort` in inline join relation HOT 5
- Nightly tests failed HOT 1
- `**` operator (or something else) for `math.pow` HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from prql.