Hacker GitHub

← All repos

transact-rs/sqlx

View on GitHub ↗ ★ 17,621 Rust

🧰 The Rust SQL Toolkit. An async, pure Rust SQL crate featuring compile-time checked queries without a DSL. Supports PostgreSQL, MySQL, and SQLite.

46 mentions on Hacker News by 40 people: 6 stories, 40 comments · first 2019-12-30 · latest 2026-02-19

Mentions per year 46 mentions · busiest year 2023 (14)
20082026
  1. Nope, it really was part of the design [1] [1] https://github.com/launchbadge/sqlx/issues/333#issuecomment-...
    comment by cogman10 · 2026-02-19 · in Farewell, Rust for web
  2. …them to not be null even though it is a left join. For more information, see the link below: https://github.com/launchbadge/sqlx/issues/367#issuecomment-... ``` Did you have other problems beyond this, or are you referring to something…
    comment by rellfy · 2025-07-29 · in SQLx – Rust SQL Toolkit
  3. …this information to check without a database available, and has a basic migration facility.) [1] https://github.com/launchbadge/sqlx/blob/main/FAQ.md#how-do-...
    comment by maxbond · 2025-07-28 · in SQLx – Rust SQL Toolkit
  4. …performance, swap out for one of the lower level libraries for the affected methods/services. [1] https://github.com/launchbadge/sqlx/commit/47f3d77e599043bc2... [2] https://crates.io/crates/rusqlite [3] https://www.sea-ql.org/SeaORM/ [4]…
    comment by no_circuit · 2025-07-28 · in SQLx – Rust SQL Toolkit
  5. …cause the database to be unexpectedly dropped. The issues I saw seem to be related to these issues: https://github.com/launchbadge/sqlx/issues/3080 https://github.com/launchbadge/sqlx/issues/2510 The problems did not manifest until the…
    comment by thesuperbigfrog · 2025-07-28 · in SQLx – Rust SQL Toolkit
  6. ▲ 180
    SQLx – Rust SQL Toolkit
    story by stmw · 2025-07-26 · 97 comments
  7. …grammatical implications should be avoided in my opinion. Check the query builder of sqlx [1] [1] https://github.com/launchbadge/sqlx/blob/main/sqlx-core/src/...
    comment by cookiengineer · 2025-01-27 · in You probably don't need query builders
  8. …there is no such tool yet in Typescript land, there are a few that are taking that direction. [0] https://github.com/launchbadge/sqlx
    comment by norman784 · 2024-12-06 · in Litdb – type safe SQL for JavaScript/TS
  9. …of if my approach will work with it, but I suppose no, because it needs to generate files. [0] https://github.com/launchbadge/sqlx
    comment by norman784 · 2024-12-06 · in Litdb – type safe SQL for JavaScript/TS
  10. This looks like a less ergonomic version of Rust's SQLx ( https://github.com/launchbadge/sqlx ) but a more robust version of TypeScript's sqlx-ts ( https://jasonshin.github.io/sqlx-ts/ ). Sqlc seems to copy the latter's unfortunate lack of…
    comment by jelder · 2024-09-10 · in Sqlc: Compile SQL to type-safe code
  11. …DB at compile time to have the database itself verify (and return some info on) your SQL queries." https://github.com/launchbadge/sqlx
  12. ▲ 2
    SQLx: Async, pure Rust SQL crate, compile-time checked queries without a DSL
    story by transportheap · 2024-07-22 · 0 comments
  13. I haven’t used Postgres but is this the issue you’re talking about? https://github.com/launchbadge/sqlx/pull/1539
    comment by jaktet · 2024-03-15 · in Postgres is eating the database world
  14. …to seamless access of set-oriented data. More stuff like this: https://github.com/porsager/postgres https://github.com/launchbadge/sqlx
    comment by ttfkam · 2024-02-19 · in Show HN: PRQL in PostgreSQL
  15. It's available to some in extend in rust, e.g. SQLX [1] allows you to typecheck queries. [1] https://github.com/launchbadge/sqlx
  16. SQLX has entered the chat [1]. [1] https://github.com/launchbadge/sqlx
  17. Like Rust's Sqlx? https://github.com/launchbadge/sqlx
    comment by ttfkam · 2023-06-29 · in Is ORM still an anti-pattern?
  18. …recommended. It has the nice feature that your queries can be verified at compile time. [1]: https://github.com/launchbadge/sqlx
  19. ▲ 5
    Ask HN: Why is there no database with a functional query language?
    story by fragile_frogs · 2023-04-19 · 5 comments
  20. …to template out HTML and it checks all my boxes, dynamic data, passing in functions, control flow. https://github.com/launchbadge/sqlx sql interface for a variety of backend, async safe. https://github.com/seanmonstar/reqwest http client…
  21. …Yes, but it can also run in 'offline' mode where it builds against saved metadata [0] 0: https://github.com/launchbadge/sqlx/blob/main/sqlx-cli/READM...
    comment by imron · 2023-03-21 · in Why use Rust on the back end?
  22. I felt the same way until I found sqlx ( https://github.com/launchbadge/sqlx ). The package lets you write sql in your app with compile-time checks. Was so much easier to get up and running than learning a new ORM.
    comment by brycelarkin · 2023-03-14 · in Things I learned after getting users
  23. …update queries by hand? Are you using compile-time checks through libraries like sqlx [1]? [1]: https://github.com/launchbadge/sqlx
    comment by akprasad · 2023-03-13 · in Things I learned after getting users
  24. Part of the solution could be using tooling which can compile time check SQL is valid like https://github.com/launchbadge/sqlx
    comment by Gigachad · 2023-02-01 · in Ask HN: How do you test SQL?
  25. …extra impressive that they manage to support not only postgres, but sqlite and and mysql too. [1] https://github.com/launchbadge/sqlx
    comment by shirogane86x · 2023-01-26 · in Kysely: TypeScript SQL Query Builder
  26. …building the macros in offline mode when a live database is not available (such as CI) [0] [0] https://github.com/launchbadge/sqlx/blob/76ae2865005cc79d569...
    comment by norman784 · 2023-01-25 · in You might not need an ORM
  27. …`!` as an escape hatch) We use it extensively for Windmill (e.g: [2]) and couldn't be happier. [1]: https://github.com/launchbadge/sqlx [2]: https://github.com/windmill-labs/windmill/blob/d60a770eb710e...
    comment by rubenfiszel · 2023-01-25 · in You might not need an ORM
  28. …and go just like web frameworks, so I really don't care for them. I use sqlx [1] when I can. 1: https://github.com/launchbadge/sqlx
    comment by throaway2342 · 2023-01-16 · in Objection to ORM Hatred (2019)
  29. …tables for common SQL dialects, a generic JSON HTTP API wrapper, etc. Stay tuned! [1] https://github.com/launchbadge/sqlx [2] https://github.com/Segfault-Inc/Multicorn [3] https://github.com/pgsql-io/multicorn2
  30. …because there's apparently enough (private, not-open-source) users who apparently still use it. ( https://github.com/launchbadge/sqlx/issues/1669 ) (Note that they also have a note about async-compat not exactly being an ideal solution and…
  31. …is getting there, with sqlx[0] you can write plain sql and it gets validated at compile time. [0] https://github.com/launchbadge/sqlx
  32. …that if it compiles it works so when you do code review you only need to review the logic :) [1] https://github.com/launchbadge/sqlx
    comment by norman784 · 2022-02-07 · in PHP – The Right Way
  33. In Rust: https://github.com/launchbadge/sqlx In Haskell: https://hackage.haskell.org/package/esqueleto Either it analyzes the given SQL to determine the in/out types of each SQL query, or it calls the database describe feature at…
    comment by maattdd · 2022-02-04 · in Go performance from version 1.2 to 1.18
  34. …( https://docs.rs/mysql_async/latest/mysql_async/ ), but recently started playing with sqlx ( https://github.com/launchbadge/sqlx ). I guess "query builder" isn't the right way to describe them, but I'm not sure what else to call them...
    comment by ragnese · 2022-01-21 · in Jodd – The Unbearable Lightness of Java
  35. …string interpolation. In terms of that JEP, the macro invocation is the policy object. [1]: https://github.com/launchbadge/sqlx
    comment by pcwalton · 2022-01-14 · in Format Strings in Rust 1.58
  36. >I don’t need orm, just automated mapping” Check out https://github.com/launchbadge/sqlx#sqlx-is-not-an-orm for an alternative approach. struct Country { country: String, count: i64 } let countries = sqlx::query_as!(Country, "SELECT…
  37. We use sqx: https://github.com/launchbadge/sqlx . The devs create and commit the up/down migration files and the cicd runner runs the migrations against the db.
  38. …process reading your source files for queries and probing the database for what will come back. https://github.com/launchbadge/sqlx/#compile-time-verificati...
    comment by PudgePacket · 2021-06-21 · in Postgres to TypeScript Interfaces and Enums
  39. …than actual SQL. [0]: https://hackage.haskell.org/package/postgresql-typed-0.6.1.2... [1]: https://github.com/launchbadge/sqlx
  40. …want to do your next CRUD app at work in rust, I don't think its going to a good experience. [0]: https://github.com/launchbadge/sqlx
    comment by akritrime · 2021-02-08 · in Rust Foundation: Hello, World
  41. Also look at https://github.com/launchbadge/sqlx . I love compile-time checked queries (it's optional). It's simple to use too, async and includes a pool.
    comment by brunoqc · 2020-07-05 · in Choosing a Rust web framework
  42. …type system, like diesel [2] (Rust), Slick [3] (Scala) and some similar Haskell projects. [1] https://github.com/launchbadge/sqlx [2] https://github.com/diesel-rs/diesel [3] https://scala-slick.org/
  43. https://github.com/launchbadge/sqlx perhaps Also hugsql for clojure and pugsql for python.
  44. ▲ 2
    Compile-Time Verified SQL Queries Without a DSL
    story by mehcode · 2020-01-04 · 0 comments
  45. ▲ 1
    The Rust SQL Toolkit 🧰
    story by feross · 2020-01-03 · 1 comment
  46. ▲ 13
    Launchbadge/Sqlx: 🧰 The Rust SQL Toolkit
    story by kristianp · 2019-12-30 · 0 comments