migration-schema-change

Plan and execute Alembic migrations with impact analysis and downgrade paths.

Updated Dec 16, 2025
One-click install
npx skills add https://github.com/adelabdelgawad/meal_request --skill migration-schema-change
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: migration-schema-change
Source: https://github.com/adelabdelgawad/meal_request/tree/main/.claude/skills/migration-schema-change
Command: npx skills add https://github.com/adelabdelgawad/meal_request --skill migration-schema-change

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This skill guides engineers in performing database migrations safely, ensuring data integrity and minimal downtime by planning changes, validating effects on HRIS sync, and mapping dependencies before applying schema updates.

Core Features & Use Cases

  • Impact-driven migration planning: Evaluate how adding, altering, or removing columns, modifying enums, or changing foreign keys affects production data and related systems.
  • Data migration patterns: Provide templates for migrating data prior to constraints, handling large datasets, and preserving rollback capability.
  • HRIS sync awareness: Identify HRIS-managed fields and adjust migrations to avoid disrupting HRIS synchronization.
  • Downgrade safety: Ensure each migration has a downgrade path and safe rollback steps.

Quick Start

Create a new Alembic revision with autogenerate and review the generated script for data migrations, then apply to a staging database and verify by running the downgrade.

Frequently Asked Questions about migration-schema-change

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

FAQPage Schema
How do I safely add or remove columns in an Alembic migration without downtime?

Safe Alembic migrations require impact analysis before applying schema changes, ensuring data migrations precede constraints and verifying HRIS sync dependencies to avoid production downtime.

What is the best way to handle data migrations before adding constraints in Alembic?

Data migrations must execute before applying constraints in Alembic to prevent data loss, using templates that migrate data first, handle large datasets, and preserve rollback capability.

How does HRIS sync affect database schema changes and foreign key modifications?

HRIS sync awareness identifies HRIS-managed fields before schema updates, allowing you to adjust migrations and prevent disruptions to HRIS synchronization when modifying foreign keys.

Can I automatically generate a downgrade path for Alembic schema changes?

Each Alembic migration requires a downgrade path with safe rollback steps, verified by applying the migration to a staging database and running the downgrade to confirm reversibility.

When do I need to evaluate foreign-key implications during an Alembic migration?

Foreign-key implications require evaluation during Alembic migrations whenever adding, altering, or removing columns, modifying enums, or changing relationships to ensure production data integrity.

How do I change enum values safely in an Alembic database migration?

Changing enum values in Alembic requires impact-driven migration planning to evaluate effects on production data and related systems, ensuring data migrations precede constraints and downgrade safety.