sqlc
awesome-go-orms
Our great sponsors
sqlc | awesome-go-orms | |
---|---|---|
169 | 4 | |
10,837 | 513 | |
5.6% | - | |
9.7 | 7.7 | |
6 days ago | 5 days ago | |
Go | Go | |
MIT License | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
sqlc
-
Give Up Sooner
"Is there a way to get sqlc to use pointers for nullable columns instead of the sql.Null types?"
-
Show HN: Sqlbind a Python library to compose raw SQL
I came across this yesterday for golang: https://sqlc.dev which is somewhat like what you want, maybe.
Not sure it allows you to parameterize table names but the basic idea is codegen from sql queries so you are working with go code (autocompletion etc).
- API completa em Golang - Parte 7
-
ORMs are nice but they are the wrong abstraction
Agreed, but tools like https://sqlc.dev, which I mention in the article, are a good trade-off that allows you to have verified, testable, SQL in your code.
- API completa em Golang - Parte 6
-
Go ORMs Compared
sqlc is not strictly a conventional ORM. It offers a unique approach by generating Go code from SQL queries. This allows developers to write SQL, which sqlc then converts into type-safe Go code, reducing the boilerplate significantly. It ensures that your queries are syntactically correct and type-safe. sqlc is ideal for those who prefer writing SQL and are looking for an efficient way to integrate it into a Go application.
-
Type-safe Data Access in Go using Prisma and sqlc
I was browsing awesome-go for ideas on how to setup my data access layer when I stumbled on sqlc. It seemed like a great option. Code generation is a strategy often used in the Go ecosystem and making my queries safe at compile time was an idea I really liked. Knex was great, but it required of me that I test thoroughly my queries at runtime and that I sanitize my query results to ensure type safety within my application.
-
Level UP your RDBMS Productivity in GO
Now, we are going to generate the code. For this purpose, we are going to use sqlc.
-
What 3rd-party libraries do you use often/all the time?
https://github.com/sqlc-dev/sqlc — for use with //go:generate
- API completa em Golang - Parte 1
awesome-go-orms
- Go and PostgreSQL
-
Show HN: React Routing in 120 lines (including comments)
> we'd see the same problem everywhere at the same scale
we do. Every C app implements its own linked list or hash table library. The entire Scheme community is nothing but toy interpreters of various stages of completeness (you can tell a project is serious when they implement call/cc). How many game engines do you think exist? It's a meme that game devs like to spend more time on their pet game engine than actually making their game. How many ORMs do you think exist for ? At least half a dozen. At least. For any given language. Python, Ruby, Go[1]. ORMs, in particular, seem to get created over and over again. Probably because they are trivial to implement and allows one to voice their opinions on SQL abstraction (bike shedding).
[1] https://github.com/d-tsuji/awesome-go-orms
-
Top Go ORMs
I created a PR to add Ent to the list. See https://github.com/d-tsuji/awesome-go-orms/pull/8
What are some alternatives?
sqlx - general purpose extensions to golang's database/sql
react-snippets - A sample of useful snippets in React
GORM - The fantastic ORM library for Golang, aims to be developer friendly
universal-router - Universal routing both for backend and frontend
SQLBoiler - Generate a Go ORM tailored to your database schema.
awesome - 😎 Awesome lists about all kinds of interesting topics
ent - An entity framework for Go
go-formatter - A curated list of awesome Go frameworks, libraries and software
jet - Type safe SQL builder with code generation and automatic query result data mapping
podium - A leaderboard backend using redis
pgx - PostgreSQL driver and toolkit for Go
go-redis-ranking - Ranking system using Go and Redis.