news.volyx.in

PRQL – A proposal for a better SQL (github.com)

650 points by maximilianroos · 1697 days ago · 292 comments on HN

Article summary

PRQL is a proposed language for transforming data, intended as a simpler and more powerful alternative to SQL. It features a pipelined approach, with a focus on readability and explicitness, and supports abstractions such as variables and functions. PRQL can be used with any database that uses SQL, as it compiles to SQL. The language is still in the proposal stage, with ongoing development and refinement.

Main themes

  • PRQL syntax and readability
  • SQL alternatives and evolution
  • Database integration and tooling
  • Query language complexity and tradeoffs
  • PRQL adoption and potential impact
  • Comparison to other languages and technologies
  • Database and ORM support
  • SQL limitations and quirks

What commenters say

  • Some commenters find PRQL's syntax more readable and easier to reason about than SQL, while others prefer the traditional SQL syntax.
  • The complexity of joins in SQL is a challenge that PRQL may not fully address, but some argue that this complexity is inherent to the domain.
  • A few commenters suggest that PRQL could benefit from integrating with existing databases and tools, rather than requiring a new database or runtime.
  • There are differing opinions on whether PRQL's approach is an improvement over SQL, with some seeing it as a useful evolution and others as unnecessary complexity.
  • Some commenters draw parallels between PRQL and other languages, such as Apache Pig or KQL, highlighting the similarities and differences.
  • The idea of a transpiler or compiler for PRQL is seen as a potential first step towards wider adoption, with some arguing that it could eventually become a target language for databases and ORMs.
  • A few commenters express skepticism about the need for a new query language, given the ubiquity and familiarity of SQL.
  • Others see PRQL as an opportunity to improve the usability and expressiveness of query languages, and to address the limitations and quirks of SQL.