Database Migration Best Practices
Standardizes database schema changes and data migrations using zero-downtime patterns and framework-specific safety checklists.
This skill provides Claude with a comprehensive framework for managing database schema and data migrations across production environments. It focuses on the expand-contract pattern to ensure zero-downtime deployments and includes specific implementation guides for popular tools like PostgreSQL, Prisma, Drizzle, Django, and golang-migrate. By enforcing safety checklists—such as avoiding full table locks and separating DDL from DML—it helps developers perform high-risk database operations with confidence and precision.
Key Features
01151 GitHub stars
02Zero-downtime deployment strategies (Expand-Contract pattern)
03Non-blocking indexing and concurrent column modification techniques
04Batched data migration patterns for high-volume backfills
05Framework-specific patterns for Prisma, Drizzle, Kysely, and Django
06Safety checklists for schema changes on large-scale production tables
Use Cases
01Altering production database schemas without interrupting application availability
02Managing large-scale data transformations and backfills using safe batching logic
03Implementing reliable migration workflows for new projects using modern ORMs