Go ORM

Open-source Go projects categorized as ORM

Top 23 Go ORM Projects

  • GORM

    The fantastic ORM library for Golang, aims to be developer friendly

  • Project mention: Go ORMs Compared | dev.to | 2024-01-18

    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.

  • ent

    An entity framework for Go

  • Project mention: Concurrency Control in Go with Ent ORM and MySQL | dev.to | 2024-03-21

    In this article, we'll delve into the world of concurrency control in Go, specifically focusing on the optimistic locking approach. We'll explore its implementation using Ent ORM to illustrate how to manage data consistency when multiple users interact with the same resource. Keep in mind that this example serves as a simplified illustration, and real-world booking systems involve a many of additional complexities. However, the core concepts presented here provide a solid foundation for understanding optimistic locking in Go applications. Feel free to explore the complete source code in my GitHub repository for a more in-depth look at the implementation.

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
  • sqlc

    Generate type-safe code from SQL

  • Project mention: FrankenPHP: The Modern PHP App Server | news.ycombinator.com | 2024-05-29

    >> Also, I can think of a number of json schemas that are impossible to replicate in Go's type system but work just fine in PHP.

    Not at all. There are some that would be painful to write "by hand". An expansive and nested set of null fields would suck if I had to spell it all out...

    https://sqlc.dev << changes everything. If you add in the YAML (and I hate yaml) you can get your JSON to DB mapping in there, as well as your validations (all output as struct tags).

    Everything else that you're going to want (transforming inputs to/from json, logging, auth) is some pretty simple middleware.

  • gf

    GoFrame is a modular, powerful, high-performance and enterprise-class application development framework of Golang. (by gogf)

  • SQLBoiler

    Generate a Go ORM tailored to your database schema.

  • Project mention: Eradicating N+1s: The Two-Phase Data Load and Render Pattern in Go | news.ycombinator.com | 2024-05-28

    If you're using Go, sqlboiler can do this for you in most common cases (e.g., fetch all the Users matching this filter, and for each User, fetch the related Company)

    https://github.com/volatiletech/sqlboiler

  • Xorm

  • go-pg

    Golang ORM with focus on PostgreSQL features and performance

  • SaaSHub

    SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives

    SaaSHub logo
  • gorp

    Go Relational Persistence - an ORM-ish library for Go

  • xo

    Command line tool to generate idiomatic Go code for SQL databases supporting PostgreSQL, MySQL, SQLite, Oracle, and Microsoft SQL Server (by xo)

  • Project mention: Open-sourcing SQX, a way to build flexible database models in Go | news.ycombinator.com | 2023-09-02

    i like xo's approach https://github.com/xo/xo but it is as is. I would love if something similar comes along that is used by db practititoners that is actively used and supported.

  • upper.io/db

    Data access layer for PostgreSQL, CockroachDB, MySQL, SQLite and MongoDB with ORM-like features.

  • bun

    SQL-first Golang ORM (by uptrace)

  • gormt

    database to golang struct

  • Storm

    Simple and powerful toolkit for BoltDB (by asdine)

  • prisma-client-go

    Prisma Client Go is an auto-generated and fully type-safe database client

  • Project mention: TypeScript dev tools in the Golang world | dev.to | 2024-05-01

    For our luck, Prisma also has a Golang cli, so you can use it straight up.

  • xorm

    xorm是一个简单而强大的Go语言ORM库,通过它可以使数据库操作非常简便。本库是基于原版xorm的定制增强版本,为xorm提供类似ibatis的配置文件及动态SQL支持,支持AcitveRecord操作 (by xormplus)

  • reform

    A better ORM for Go, based on non-empty interfaces and code generation. (by go-reform)

  • gobuffalo/pop

    A Tasty Treat For All Your Database Needs (by gobuffalo)

  • go-doudou

    go-doudou(doudou pronounce /dəudəu/)is OpenAPI 3.0 (for REST) spec and Protobuf v3 (for grpc) based lightweight microservice framework. It supports monolith service application as well.

  • go-sqlbuilder

    A flexible and powerful SQL string builder library plus a zero-config ORM.

  • gocqlx

    All-In-One: CQL query builder, ORM and migration tool

  • REL

    :gem: Modern ORM for Golang - Testable, Extendable and Crafted Into a Clean and Elegant API

  • Project mention: Prisma for Go vs. Node.js Prisma Client &amp; GORM: Thoughts? | /r/golang | 2023-12-10
  • godb

    A Go SQL query builder and struct mapper.

  • go-queryset

    100% type-safe ORM for Go (Golang) with code generation and MySQL, PostgreSQL, Sqlite3, SQL Server support. GORM under the hood.

  • SaaSHub

    SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives

    SaaSHub logo
NOTE: The open source projects on this list are ordered by number of github stars. The number of mentions indicates repo mentiontions in the last 12 Months or since we started tracking (Dec 2020).

Go ORM related posts

  • TypeScript dev tools in the Golang world

    1 project | dev.to | 1 May 2024
  • Show HN: Riza – Safely run untrusted code from your app

    1 project | news.ycombinator.com | 30 Apr 2024
  • Concurrency Control in Go with Ent ORM and MySQL

    2 projects | dev.to | 21 Mar 2024
  • Give Up Sooner

    1 project | dev.to | 13 Mar 2024
  • Prisma Client Go: Typesafe Database Client for Golang

    1 project | news.ycombinator.com | 20 Jan 2024
  • Go ORMs Compared

    5 projects | dev.to | 18 Jan 2024
  • Stop using entgo...please

    2 projects | dev.to | 8 Jan 2024
  • A note from our sponsor - SaaSHub
    www.saashub.com | 3 Jun 2024
    SaaSHub helps you find the best software and product alternatives Learn more →

Index

What are some of the best open-source ORM projects in Go? This list will help you:

Project Stars
1 GORM 35,771
2 ent 15,042
3 sqlc 11,288
4 gf 10,972
5 SQLBoiler 6,502
6 Xorm 6,204
7 go-pg 5,599
8 gorp 3,719
9 xo 3,584
10 upper.io/db 3,487
11 bun 3,359
12 gormt 2,324
13 Storm 2,043
14 prisma-client-go 1,979
15 xorm 1,551
16 reform 1,435
17 gobuffalo/pop 1,411
18 go-doudou 1,398
19 go-sqlbuilder 1,225
20 gocqlx 890
21 REL 743
22 godb 728
23 go-queryset 723

Sponsored
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com