flyway-migration

Automate versioned database migrations with Flyway SQL scripts.

1|1|Updated Feb 2, 2026
One-click install
npx skills add https://github.com/navikt/watson-sak-frontend --skill flyway-migration-navikt
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: flyway-migration
Source: https://github.com/navikt/watson-sak-frontend/tree/main/.opencode/skills/flyway-migration
Command: npx skills add https://github.com/navikt/watson-sak-frontend --skill flyway-migration-navikt

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Facilitates controlled, versioned database schema evolution by providing Flyway migration patterns and SQL scripts that track changes over time.

Core Features & Use Cases

  • Migration file naming: use V{version}__{description}.sql conventions for predictable ordering.
  • Schema changes: create tables, add columns, create indexes, and apply data migrations with safety checks.
  • Kotlin/Java integration: sample code to run migrations programmatically within backend services.

Quick Start

Configure Flyway in your Kotlin/Java project and begin applying versioned SQL migrations with V-prefixed script files.

Frequently Asked Questions about flyway-migration

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

FAQPage Schema
How do I automate versioned database schema migrations in a Kotlin backend?

Automate versioned database schema migrations by configuring Flyway in your Kotlin project and applying SQL scripts with V-prefixed file names. This pattern ensures controlled schema evolution and tracks changes over time across environments.

What is the correct Flyway migration file naming convention for predictable ordering?

The correct Flyway migration file naming convention is V{version}__{description}.sql. This standard format ensures predictable ordering and tracking of SQL scripts as they apply schema changes like table creation and column additions.

Can I run Flyway migrations programmatically within a Java service?

Yes, you can run Flyway migrations programmatically within a Java service. The approach provides sample code for Kotlin and Java integration, allowing backend services to execute controlled database schema evolution directly.

How do I safely apply data migrations and add columns to an existing database?

Safely apply data migrations and add columns by using versioned SQL scripts with built-in safety checks. This Flyway pattern facilitates creating tables, adding columns, and creating indexes while tracking schema changes over time.

Does Flyway support schema evolution across multiple environments?

Yes, Flyway supports schema evolution across multiple environments. It automates versioned database migrations using SQL scripts, ensuring controlled schema changes like table creation and index maintenance are applied consistently.

What are the limitations of using versioned SQL scripts for database schema changes?

Limitations of using versioned SQL scripts include managing complex data migrations safely and maintaining strict V{version}__{description}.sql naming conventions. You must ensure predictable ordering and apply safety checks when evolving schemas across environments.