Automates the generation of timestamped MySQL migration files for the OWID database schema.
Install
mkdir -p .claude/skills/create-migration && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/3806" && unzip -o skill.zip -d .claude/skills/create-migration && rm skill.zipInstalls to .claude/skills/create-migration
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Create a new database migration file for the OWID MySQL database. Use when the user needs to create a database schema change or migration.Key capabilities
- →Generates timestamp-prefixed migration files
- →Enforces directory placement in db/migration/
- →Provides valid file path references after creation
How it works
Wraps a database migration generator CLI command to ensure naming conventions and file directory placement remain consistent.
Inputs & outputs
When to use create-migration
- →Adding a new index to a table
- →Creating an audit log table
- →Removing deprecated columns from the schema
About this skill
Create Database Migration
Create a new database migration file for the OWID MySQL 8 database.
Steps
- Run
yarn createDbMigration db/migration/<NewMigrationName>where<NewMigrationName>is a descriptive name for the migration - The generated filename will contain a timestamp prefix, so scan the
db/migration/directory to find the actual path of the new file - Report the new file path to the user
Naming Guidelines
Choose a descriptive name for the migration that clearly indicates what schema change is being made (e.g., AddUserEmailIndex, CreateAuditLogTable, RemoveDeprecatedColumns).
Writing the Migration
Read db/readme.md before populating the file. In particular: use past migrations in db/migration/ as reference, and always write a down migration in case the change needs to be reverted.
After Writing the Migration
Follow the checklist in db/migration/CLAUDE.md: recreate any views referencing modified columns, update the DB type definitions in packages/@ourworldindata/types/src/dbTypes/, update the table docs in db/docs/, and tell the user the owid/etl and owid/analytics repositories may need adjusting.
When not to use it
- →Direct database editing via manual SQL queries
- →Updating production databases directly
Prerequisites
Limitations
- →Only compatible with the specific OWID project structure
- →Does not automate the contents of the migration file itself
How it compares
It enforces naming guidelines and pathing standardization, eliminating common manual errors in schema versioning.
Compared to similar skills
create-migration side by side with the closest alternatives in the catalog.
| Skill | Installs | Updated | Safety | Difficulty |
|---|---|---|---|---|
| create-migration (this skill) | 1 | 3mo | No flags | Beginner |
| database-migration | 3 | 2mo | No flags | Advanced |
| prisma-v7 | 0 | 3mo | No flags | Intermediate |
| agentdb-advanced-features | 7 | 9mo | Review | Advanced |
Try saying
Example prompts that trigger this skill in your AI assistant.
You might also like
database-migration
wshobson
Execute database migrations across ORMs and platforms with zero-downtime strategies, data transformation, and rollback procedures. Use when migrating databases, changing schemas, performing data transformations, or implementing zero-downtime deployment strategies.
prisma-v7
develsvai
`web/`의 Prisma 7 설정과 generated client import 규칙을 맞추기 위한 스킬이다. 스키마 변경, migration, import 패턴 정리, Prisma 타입 사용 시 적용한다.
agentdb-advanced-features
ruvnet
Master advanced AgentDB features including QUIC synchronization, multi-database management, custom distance metrics, hybrid search, and distributed systems integration. Use when building distributed AI systems, multi-agent coordination, or advanced vector search applications.
senior-backend
davila7
Comprehensive backend development skill for building scalable backend systems using NodeJS, Express, Go, Python, Postgres, GraphQL, REST APIs. Includes API scaffolding, database optimization, security implementation, and performance tuning. Use when designing APIs, optimizing database queries, implementing business logic, handling authentication/authorization, or reviewing backend code.
redis-inspect
civitai
Inspect Redis cache keys, values, and TTLs for debugging. Supports both main cache and system cache. Use for debugging cache issues, checking cached values, and monitoring cache state. Read-only by default.
prisma-connection-pool-exhaustion
blader
Fix Prisma "Too many connections" and connection pool exhaustion errors in serverless environments (Vercel, AWS Lambda, Netlify). Use when: (1) Error "P2024: Timed out fetching a new connection from the pool", (2) PostgreSQL "too many connections for role", (3) Database works locally but fails in production serverless, (4) Intermittent database timeouts under load.