down a migration rails code example Example 1: ruby on rails db migrate rails db:migrate Example 2: rails redo last migration rake db:migrate:redo STEP=n