GORM
bun
GORM | bun | |
---|---|---|
81 | 18 | |
37,092 | 3,848 | |
0.7% | 3.5% | |
8.2 | 9.1 | |
13 days ago | 5 days ago | |
Go | Go | |
MIT License | BSD 2-clause "Simplified" 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.
GORM
-
How to use migrations with Golang
Go doesn't support migrations natively for that propuso we can use the popular golang-migrate package also if you use an ORM like GORM you can use it for that.
-
Toasty, an Async ORM for Rust
I never understood why people are so stubborn about hating on orm.
For example I'm familiar with https://gorm.io and it does save me a lot of time and useless boilerplate.
And guess what, if I ever need to make a complex query, I also happen to know SQL, and I'm just going to make a "raw" query https://gorm.io/docs/sql_builder.html#Raw-SQL and be done with it.
It's not all that hard.
-
Building a RESTful API with Go Fiber: An Express-Inspired Boilerplate
SQL database: PostgreSQL Object Relation Mapping using Gorm
-
Store IoT device data
The previous post demonstrated receiving the raw data and unmarshalling it into a struct that was already annotated with gorm tags. Gorm is a popular ORM for Go. If you are not familiar with it, you can for more information here.
-
GORM, PostgreSQL & Atlas
GORM is a, quite conveniently named, ORM for GO
-
Scaling Backend to 1M requests with just 2GB ram ⚡️
Written in GIN framework and uses GORM as ORM.
-
How to handle migrations in Golang
There are ORMs like gorm that supports some kind of documentation with files, but they mainly focus on converting the database to "things" in the code to be used by the ORM, and not as documentation only/documentation-first.
-
Go ORMs Compared
GORM is a comprehensive ORM tool in Go, offering a code-first approach which allows defining database schemas using struct tags in Go. It's known for its developer-friendly nature, making it suitable for both beginners and experienced users. GORM supports a variety of SQL databases like MySQL, PostgreSQL, and SQLite. It's designed to be flexible, allowing developers to drop down to raw SQL when necessary. However, it's important to be cautious about its performance implications in large-scale applications.
-
6 🔥 Awesome Golang packages (web devs)
Homepage: https://gorm.io/
- Tenha controle sobre seu SQL com Golang e SQLC
bun
-
ORM or no ORM (and which ones)?
This way: https://github.com/uptrace/bun, I prefer in all cases with PostgreSQL
- When creating an API (or even a website) what's the best practice of initializing a database connection and using it across the application where it's necessary?
-
Best packages?
https://github.com/uptrace/bun For SQL building.
-
Which ORM framework are you using with golang, and why?
I use Bun by Uptrace - https://github.com/uptrace/bun
-
What’s your preferred setup to work with SQL DB (without ORM) ?
Though, i've would give a try to bun
-
What SQL library are you using?
Bun would be my choice, it spans a nice gap between full ORM and query builder - https://github.com/uptrace/bun
- Bun – SQL-first Golang ORM for PostgreSQL, MySQL, mssql, and SQLite
-
Bun: SQL-first Golang ORM
To get started, see the documentation and run examples.
-
SQL Query Strategy for complex structs
bun and go-pg both seem to work fairly well for these kind of purposes.
- Bun v1.1 SQL client adds supports for MSSQL
What are some alternatives?
ent - An entity framework for Go
Xorm
go-pg - Golang ORM with focus on PostgreSQL features and performance
SQLBoiler - Generate a Go ORM tailored to your database schema.
sqlc - Generate type-safe code from SQL
pgx - PostgreSQL driver and toolkit for Go
prisma-client-go - Prisma Client Go is an auto-generated and fully type-safe database client
Squirrel - Fluent SQL generation for golang
beego orm
go-sqlite - Low-level Go interface to SQLite 3