Our great sponsors
-
When I don't use one, I'm typically using SQLx or (if using Postgres) pgx with scany https://github.com/georgysavva/scany (slightly better API than SQLx and great performance since you can use the native interface from pgx if desired whereas many database drivers only offer the text-based interface).
-
I think the best ORM in Go is Ent: https://entgo.io/ It has great docs, great migration capabilities, and is well run with professional staff. The only downside is that some people don't like the approach of code generation.
-
InfluxDB
Access the most powerful time series database as a service. Ingest, store, & analyze all types of time series data in a fully-managed, purpose-built database. Keep data forever with low-cost storage and superior data compression.
-
-
I have been using: https://sqlc.dev/ With pgx for Postgres and liking it so far. It does code generation. But seems pretty easy to maintain. And there is no reflection at runtime, so performance is good.
-
sqlboiler
-
But using a query builder, something like squirrel or (plug) bqb, allows you to actually write SQL (or something close to it) when you need it but also handles the nasty string building bits. Though I agree that ORMs are not always bad, especially for small projects with well-defined scope.
-
bqb
BQB is a lightweight and easy to use query builder that works with sqlite, mysql, mariadb, postgres, and others.
But using a query builder, something like squirrel or (plug) bqb, allows you to actually write SQL (or something close to it) when you need it but also handles the nasty string building bits. Though I agree that ORMs are not always bad, especially for small projects with well-defined scope.
-
SonarQube
Static code analysis for 29 languages.. Your projects are multi-language. So is SonarQube analysis. Find Bugs, Vulnerabilities, Security Hotspots, and Code Smells so you can release quality code every time. Get started analyzing your projects today for free.