Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

sqlx is my favorite way of working with databases in Rust hands down.

I've tried alternatives like Diesel and sea-orm. To be honest, I feel like full-blown ORMs really aren't a very good experience in Rust. They work great for dynamic languages in a lot of cases, but trying to tie in a DB schema into Rust's type system often creates a ton of issues once you try to do anything more than a basic query.

It's got a nice little migration system too with sqlx-cli which is solid.



I’ve used Diesel for a bit now but haven’t had issues wrangling the type system. Can you give an example of an issue you’ve encountered?


This has been exactly my experience! I've found SQLx to be a joy to work with in Rust!


Same. Never again diesel. The type system just turns it into madness. Sqlx is a much more natural fit.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: