Tern - The SQL Fan's Migrator

Tern - The SQL Fan’s Migrator

Tern is designed to simplify migrating database schemas with views,
functions,
triggers, constraints and other objects where altering one may require
dropping
and recreating others. For example, if view A selects from view B which
selects
from table C, then altering C could require five steps: drop A, drop B,
alter
C, recreate B, and recreate A. Tern can be told to alter C and it will
automatically perform the other four steps.

Installation

 gem install tern

Check it out: GitHub - jackc/tern: The SQL Fan's Migrator

Jack