Take the 2-minute tour ×

I want to know if there is a short way to do the migrations down equivalent to rake db:migrate (for the migrations up). Instead of doing : rake db:migrate:up VERSION=1, rake db:migrate:up VERSION=2, ... we can do : rake db:migrate! But for : rake db:migrate:down VERSION=10, rake db:migrate:down VERSION=..., rake db:migrate:down VERSION=1, is there a shortcut?

Tank you for your help!

share|improve this question

2 Answers 2

up vote 14 down vote accepted

rake db:migrate VERSION=0 will remove all migrations, if that's what you're trying to do.

share|improve this answer
Thank you, it was exactly what I was looking for! –  Michaël May 30 '10 at 22:03
wont work with rails 3.1 –  Flakerim Sep 26 '11 at 16:27
Works with Rails 3.2.13 –  Arman H May 16 '13 at 1:56

I don't think there is a premade task for doing what you want. You can see all of the available rake tasks using rake -T.

share|improve this answer

Your Answer


