SaaSHub helps you find the best software and product alternatives Learn more →
Top 23 Go SQL Projects
-
tidb
TiDB - the open-source, cloud-native, distributed SQL database designed for modern applications.
Project mention: RocksDB: Your Key-Value Store Powerhouse (and Why You Should Care) | dev.to | 2025-02-16TiDB: https://pingcap.com/
-
InfluxDB
InfluxDB – Built for High-Performance Time Series Workloads. InfluxDB 3 OSS is now GA. Transform, enrich, and act on time series data directly in the database. Automate critical tasks and eliminate the need to move data externally. Download now.
-
cockroach
CockroachDB — the cloud native, distributed SQL database designed for high availability, effortless scale, and control over data placement.
Employ distributed databases like CockroachDB, Cassandra, or managed services like Amazon Aurora Global Databases.
-
Before Dolt appeared on my radar, I thought this problem was non-trivial, and very difficult to implement: Whenever a fork occurs, or blocks arrive at your node that conflict with your current chain, you have to validate these new blocks against a snapshot of your data at a specific point in time. This point in time is determined by the parent block hash of the incoming blocks. This requirement for "time-travel" has always deterred me from attempting my own blockchain implementation. I know that there are blockchains out there that have (maybe?) solved this, but I'm not as good as a programmer as those guys. If you're anything like me, maybe you can relate.
-
Project mention: Mastering Database Migrations in Go with golang-migrate and SQLite | dev.to | 2025-04-14
Managing database changes is critical for any software project. This guide walks you through using golang-migrate with SQLite in Go to handle migrations cleanly and consistently.
-
I have been following Ben for a long time but I never knew LiteFS was based on his work. I somehow settled eventually for rqlite for self managed distributed.
https://github.com/rqlite/rqlite
-
-
go-sql-driver/mysql
Go MySQL Driver is a MySQL driver for Go's (golang) database/sql package (by go-sql-driver)
Next, we need to install some dependencies. We already know we are using MySQL as our database, thus, we need to install the MySQL driver for Golang.
-
SaaSHub
SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives
-
https://dev.to/booscaaa/implementando-clean-architecture-com-golang-4n0a https://github.com/golang-standards/project-layout https://blog.boot.dev/golang/golang-project-structure/ https://github.com/bnkamalesh/goapp https://www.wolfe.id.au/2020/03/10/how-do-i-structure-my-go-project/ https://blog.logrocket.com/flat-structure-vs-layered-architecture-structuring-your-go-app/ https://developer20.com/how-to-structure-go-code/ https://dev.to/jinxankit/go-project-structure-and-guidelines-4ccm https://github.com/bxcodec/go-clean-arch https://golangexample.com/example-go-clean-architecture-folder-pattern/ https://www.calhoun.io/flat-application-structure/ https://go.dev/doc/effective_go#names https://go.dev/blog/package-names
-
frameworks / ORM are just specilized database graphical user interface front ends designed to simplify how data is displayed/inputed
Database management systems usually provide a way of importing/exporting 'raw' data via sql statement(s) results. aka cvs, comma delimited, html formatted, json formatted, etc. aka do command line sql query with 'html formatted output' and open results of file in a brower.
postgres psql provides an interactive 'cli' environment; windows sql server - sqlcmd;
usql[1] provides something similar to psql for no-sql databases.
sqlc is sorta the equivalent of combining the command line shell & sql queries. SQLx rust is rust extention for handling 'sql from command line, just via rust language, instead of going through command line shell.'
----
[1] : https://github.com/xo/usql
-
immudb
immudb - immutable database based on zero trust, SQL/Key-Value/Document model, tamperproof, data change history
Project mention: ImmuDB: Merging Blockchain Data Integrity with Innovative Open Source Funding | dev.to | 2025-05-12For more technical deep-dives into blockchain-based open source funding or to explore how these principles apply across technology sectors, visit ImmuDB's official site and browse related resources such as Open Source Developer Support Programs for guidance.
-
goose
-
Project mention: Princípios SOLID em GoLang - Dependency Inversion Principle (DIP) | dev.to | 2024-08-03
-
-
cloudnative-pg
CloudNativePG is a comprehensive platform designed to seamlessly manage PostgreSQL databases within Kubernetes environments, covering the entire operational lifecycle from initial deployment to ongoing maintenance
Project mention: Xata: Postgres at scale, with copy-on-write branching and anonymization | news.ycombinator.com | 2025-05-17> we deploy the Postgres instances on Kubernetes via the CloudNativePG operator.
I'm curious if split brain cases already happeened. At scale, it should be so https://github.com/cloudnative-pg/cloudnative-pg/issues/7407
-
-
octosql
OctoSQL is a query tool that allows you to join, analyse and transform data from multiple databases and file formats using SQL.
-
-
xo
Command line tool to generate idiomatic Go code for SQL databases supporting PostgreSQL, MySQL, SQLite, Oracle, and Microsoft SQL Server
XO doesn’t have them built-in, but it uses easily customizable templates.
I added support for a bunch of postgres fancy stuff in a previous app, it wasn’t too difficult
https://github.com/xo/xo
-
-
upper.io/db
Data Access Layer (DAL) for PostgreSQL, CockroachDB, MySQL, SQLite and MongoDB with ORM-like features.
-
mergestat-lite
Query git repositories with SQL. Generate reports, perform status checks, analyze codebases. 🔍 📊
Project mention: Show HN: "Git who" – A new CLI tool for industrial-scale Git blaming | news.ycombinator.com | 2025-03-18This is such a cool tool. It's a better approach to solving many of the questions I built MergeStat to answer (https://github.com/mergestat/mergestat-lite). It's been some time, but I also wrote a `git blame ...` parser in Go: https://github.com/mergestat/gitutils/blob/main/blame/blame.... :)
Amazing work and excited to dig into this more thoroughly
-
-
It gets mentioned a lot in the context of database/sql and sqlc alternatives, but Jet has been a great alternative so far, most notably because of its non-issue with dynamic queries support.
https://github.com/go-jet/jet/
-
SaaSHub
SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives
Go SQL discussion
Go SQL related posts
-
Stoolap: High-performance, SQL database in pure Go with zero dependencies
-
Ask HN: What's your go-to message queue in 2025?
-
Show HN: TextQuery – Query CSV, JSON, XLSX Files with SQL
-
Cloud-Native Architectures: Building Resilient Systems
-
Sqlc: Generate type-safe code from SQL
-
Go channels are bad and you should feel bad (2016)
-
Dolt as a backing database for blockchains
-
A note from our sponsor - SaaSHub
www.saashub.com | 23 May 2025
Index
What are some of the best open-source SQL projects in Go? This list will help you:
# | Project | Stars |
---|---|---|
1 | tidb | 38,473 |
2 | cockroach | 30,895 |
3 | dolt | 18,676 |
4 | migrate | 16,672 |
5 | rqlite | 16,609 |
6 | sqlc | 15,023 |
7 | go-sql-driver/mysql | 14,799 |
8 | go-clean-arch | 9,520 |
9 | usql | 9,365 |
10 | immudb | 8,742 |
11 | goose | 8,392 |
12 | go-sqlmock | 6,354 |
13 | cloudquery | 6,092 |
14 | cloudnative-pg | 5,973 |
15 | go-pg | 5,716 |
16 | octosql | 5,036 |
17 | bun | 4,163 |
18 | xo | 3,817 |
19 | dsq | 3,792 |
20 | upper.io/db | 3,595 |
21 | mergestat-lite | 3,500 |
22 | sql-migrate | 3,330 |
23 | jet | 3,179 |