do-entity-store

Generates SQL migration files and sqlc CRUD queries for Go domain entities.

1|Updated Mar 8, 2026
One-click install
npx skills add https://github.com/viqueen/claude-go-playground --skill do-entity-store
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: do-entity-store
Source: https://github.com/viqueen/claude-go-playground/tree/main/.claude/skills/do-entity-store
Command: npx skills add https://github.com/viqueen/claude-go-playground --skill do-entity-store

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill automates the creation of database schemas and queries for new entities within a domain, ensuring data models align with API contracts and follow best practices.

Core Features & Use Cases

  • SQL Migration Generation: Creates schema and table definitions for new entities, including relationships and soft-delete support.
  • SQLC Query Generation: Generates full CRUD (Create, Read, Update, Delete) queries for each entity, optimized for Go integration.
  • Use Case: When adding a new 'product' entity to the 'catalog' domain, this Skill will generate the necessary SQL migration file and the corresponding sqlc query files, ready for integration into the backend.

Quick Start

Use the do-entity-store skill to create the SQL migration and queries for the 'user' entity in the 'auth' domain.

Frequently Asked Questions about do-entity-store

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate SQL migrations and sqlc queries for a new Go backend entity?

You can generate SQL migration files and sqlc query definitions by specifying the entity and domain name, which creates tables with UUID primary keys, TIMESTAMPTZ timestamps, soft-delete columns, and full CRUD operations following sqlc conventions for required and optional arguments.

What does sqlc convention require for optional arguments in generated CRUD queries?

The sqlc convention for optional arguments in generated CRUD queries involves applying specific parameter filtering, such as filtering for active records to exclude soft-deleted entries, ensuring queries handle both required and optional arguments correctly in the Go backend.

Can I add foreign key constraints and soft-delete columns when creating SQL schema migrations?

Yes, you can add foreign key constraints and soft-delete columns when creating SQL schema migrations. The Skill supports generating tables with these constraints, alongside UUID primary keys and TIMESTAMPTZ timestamps, and automatically updates the sqlc.yaml configuration for PostgreSQL.

Does this SQL migration generator support list-by-parent queries for related entities?

Yes, this SQL migration generator supports list-by-parent queries for related entities. It generates full CRUD operations, including specialized list-by-parent queries, ensuring you can efficiently retrieve child records mapped to a parent domain entity using sqlc.

How do I update sqlc.yaml for PostgreSQL when adding new database schemas?

You update sqlc.yaml for PostgreSQL automatically when generating new database schemas. The Skill configures the sqlc.yaml file during migration and query generation to ensure the PostgreSQL connection and schema mappings are correctly defined for the new entity.