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
20082026
-
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 -
…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 -
…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 -
…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 -
…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 -
…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 -
…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 -
…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 -
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 -
…DB at compile time to have the database itself verify (and return some info on) your SQL queries." https://github.com/launchbadge/sqlx
comment by khimaros · 2024-08-18 · in Build your own SQLite, Part 1: Listing tables -
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 -
…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 -
It's available to some in extend in rust, e.g. SQLX [1] allows you to typecheck queries. [1] https://github.com/launchbadge/sqlx
comment by PartiallyTyped · 2023-11-05 · in A new F# compiler feature: graph-based type-checking -
SQLX has entered the chat [1]. [1] https://github.com/launchbadge/sqlx
comment by PartiallyTyped · 2023-11-05 · in A new F# compiler feature: graph-based type-checking -
Like Rust's Sqlx? https://github.com/launchbadge/sqlx
comment by ttfkam · 2023-06-29 · in Is ORM still an anti-pattern? -
…recommended. It has the nice feature that your queries can be verified at compile time. [1]: https://github.com/launchbadge/sqlx
comment by lwhsiao · 2023-05-12 · in Hyper – A fast and correct HTTP implementation for Rust -
…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…
comment by boredumb · 2023-04-11 · in Becoming Rustacean: Resources to Learn Rust Programming -
…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? -
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 -
…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 -
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? -
…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 -
…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 -
…`!` 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 -
…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) -
…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
comment by oliverrice · 2022-12-15 · in Supabase Wrappers: A framework for building Postgres foreign data wrappers -
…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…
comment by Klonoar · 2022-10-05 · in Show HN: Async UI: A Rust UI Library Where Everything is a Future -
…is getting there, with sqlx[0] you can write plain sql and it gets validated at compile time. [0] https://github.com/launchbadge/sqlx
comment by norman784 · 2022-04-26 · in Sorbet and 100% cov makes Ruby refactoring possible -
…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 -
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 -
…( 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 -
…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 -
>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…
comment by iknowstuff · 2021-11-23 · in Back to basics: Writing an application using Go and PostgreSQL -
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.
comment by jguzmanjr · 2021-09-21 · in Ask HN: How do you handle CI/CD for databases -
…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 -
…than actual SQL. [0]: https://hackage.haskell.org/package/postgresql-typed-0.6.1.2... [1]: https://github.com/launchbadge/sqlx
comment by hardwaresofton · 2021-02-22 · in SwiftGraphQL – A GraphQL client that lets you forget about GraphQL -
…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 -
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 -
…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/
comment by the_duke · 2020-05-25 · in Show HN: PgTyped – Typesafe SQL in TypeScript and Postgres -
https://github.com/launchbadge/sqlx perhaps Also hugsql for clojure and pugsql for python.
comment by aganame · 2020-05-25 · in Show HN: PgTyped – Typesafe SQL in TypeScript and Postgres