5 ms·
Thanks for the reminder. I knew this was reminding me of something! Here's a previous discussion on PRQL: https://news.ycombinator.com/item?id=31897430 https:
by nmstoker 4y ago
Thanks for the reminder. I knew this was reminding me of something!
Here's a previous discussion on PRQL:
https://news.ycombinator.com/item?id=31897430 https://news.ycombinator.com/item?id=31897430
- snthpy 4y agoFull disclosure: I'm a PRQL contributor. There will be a big PRQL release in January which makes that previous discussion look quite dated. Best source for current state is the prql-lang.org website and the github repo (github.com/PRQL/prql). Also try the playground - there you can live queries on real data in your browser.
- cbsmith 4y agoHey, maybe you can help me with something about PRQL that I've never bothered to investigate (and I'll confess this is laziness on my part). If newlines just extend a pipeline, what separates pipelines? Do semicolons separate pipelines just like they separate queries in SQL?
- snthpy 4y agoI don't recall us discussing that before. You can have named pipelines which basically become CTEs, like table employees_usa = (from employees | filter country=='USA') but ultimately there is usually just one "main" pipeline/query per file/input. Because PRQL only targets queries / DQL at the moment, I'm not sure what the sense multiple pipelines per file would be at this point. You're welcome to open an issue or start a discussion on the Github repo about your use case though, we'd love to hear about it!
- usgroup 4y agoDoes PRQL allow for a shared library? Ie can fragments be saved and reused?
- snthpy 4y agoThat's definitely on the roadmap but we're not quite there yet. With the next release you will be able to create functions that are reusable pipeline segments (e.g. something like "top 5 items per group"). This works at the moment but is currently undocumented. Do expect there to be breaking changes on this still though as there are some issues around resolving names and namespaces etc... that we still need to work out. There is a (currently rather small) stdlib of functions but beyond that we still need to think about a good way to share code and create reusable libraries.
- usgroup 4y agoI think a composable SQL alternative would be great but if doesn't compose I personally don't see too much value in just an alternative syntax.
- civilized 4y agoThank you for giving so much credit to dplyr in your FAQ. The influence is obvious and I think dplyr deserves more credit for its revolutionary design, which has influenced a whole new generation of data manipulation tools. (I am not affiliated with dplyr/R/RStudio in any way, just a huge fan.)