Go SQL and transactions
Writes Go database code with sound pooling, transactions, migrations and sqlc, GORM or ent for safe queries.
Claude's review
8/10 Go database patterns with pool settings, transaction helper, concurrency control and a thorough checklist
We asked Claude the question you would ask: would I be glad I installed this? We only sell skills it rates 7 or higher.
In detail
Database patterns for Go services: database/sql, connection management, transactions, migrations, query builders, and ORM usage (sqlc, GORM, ent). Use when: "database access", "SQL query", "connection pool", "transactions", "database migration", "sqlc", "GORM", "ent", "prepared statement", "repository pattern". Not for: in-memory structures (go-data-structures), SQL security (go-security-audit), query profiling (go-performance-review).
How you use it
- Add it to your pack, then download your pack (1 credit).
- In Claude, open Customize > Skills and upload the zip. Code execution needs to be on under Settings > Capabilities.
- Ask Claude for the job in your own words. It uses the skill when your request matches what it does. Step by step guide
Safety check
Nothing risky found: no hidden instructions, no download and run, no reading of saved passwords or keys.
An automated scan lowers risk but cannot promise zero risk. How we check skills
Preview
The first lines of SKILL.md
---
name: go-database
description: >
Database patterns for Go services: database/sql, connection management,
transactions, migrations, query builders, and ORM usage (sqlc, GORM, ent).
Use when: "database access", "SQL query", "connection pool",
"transactions", "database migration", "sqlc", "GORM", "ent", "prepared
statement", "repository pattern".
Not for: in-memory structures (go-data-structures), SQL security
(go-security-audit), query profiling (go-performance-review).
user-invocable: true
license: MIT
compatibility: Designed for Claude Code or similar AI coding agents working on Go projects. Requires the Go toolchain. sqlc, golang-migrate and Docker are optional.
allowed-tools: Read Edit Write Glob Grep Bash(go:*) Bash(gofmt:*)
metadata:
author: eduardo-sl
version: "1.5.1"
---
# Go Database Patterns
Database access is where most Go services spend their complexity budget.
Get connection management, transactions, and query patterns right.
> Community default. A project skill or agent-config rule that explicitly
> supersedes `go-database` takes precedence over this one.
Detailed reference material, loaded on demand:
- `references/query-patterns.md` — full query/scan/rows patterns, null
handling, N+1 avoidance, connection-leak examples.
- `references/tooling.md` — repository pattern implementation, sqlc
annotated queries, migration tooling and rules.
- `references/locking-and-retries.md` — `FOR UPDATE`/`SKIP LOCKED`,
optimistic versioning, retrying `40001`/`40P01`, constraint errors.
- `references/performance.md` — COPY and batched inserts, keyset
pagination, pool statistics, `sql.Null[T]`.
- `references/testing.md` — choosing fakes vs a real database,
testcontainers setup, isolation strategies.
...From eduardo-sl's repository, MIT licence.
Related skills
-
Checked
PostgreSQL schema explorer
Explores an unfamiliar PostgreSQL database read only before writing SQL, so answers about your data are right.
7/101 credit -
Checked
HTTP API design review
Designs or reviews HTTP endpoints, auth, pagination and versioning, so API changes do not break your clients.
7/101 credit -
Checked
Firebase Data Connect
Builds and deploys Firebase Data Connect backends on PostgreSQL with secure queries and type safe SDKs.
7/101 credit -
Checked
App performance tuning
Measures first, then fixes slow pages, Core Web Vitals and N+1 database queries across your whole app.
7/101 credit -
Checked
Safe Postgres migrations
Plans and tests PostgreSQL schema changes with lock levels in mind, so live tables change without downtime.
8/101 credit -
Checked
Supabase auth and database
Builds with Supabase auth, database, storage and edge functions while avoiding common security traps.
8/101 credit