4 ms·
I'm not a big fan of Active Record (https://kev.inburke.com/kevin/faster-correct-database-queries/ https://kev.inburke.com/kevin/faster-correct-database-querie.
by kevinburke 10y ago
I'm not a big fan of Active Record (https://kev.inburke.com/kevin/faster-correct-database-queries/ https://kev.inburke.com/kevin/faster-correct-database-querie...) and tend to just write queries by hand. The benefit of this is you can Prepare them, which alerts you to syntax errors earlier and means the database doesn't have to parse the query each time you execute it.
You also don't need to return every column if you know you only need an email address.
I know people that have had success with gorm or sqlx.