title: Why might "rake db:migrate" and "rake db:rollback" not roll back more than one migration at a time?
body: <p>I'm getting some unexpected behaviour with <code>rake db:migrate</code> and <code>rake db:rollback</code>. Am hoping someone might be able to shed some light for me.</p>
  
  <p>I made a mess of my migrations by adding a conflicting one in, and I'm trying to migrate back to 0 so that I can migrate up again and continue knowing that everything is going to work OK.</p>
  
  <p>I was running <code>rake db:migrate version=0</code> and just getting dumped back at the command line, with no migrations reported and no effects on my database. I do have a Rakefile, and my database.yml file is set up with correct login credentials.</p>
  
  <p>Playing around, I found I was able to go <code>rake db:rollback step=1</code> with no problems: the appropriate actions would happen as per the migrations. However, <code>rake db:rollback step=2</code> (or step=3 or step=5 -- anything other than 1) would only ever do one migration at a time.</p>
  
  <p>Used mysql in the terminal to drop the database entirely. Recreated it, then went <code>rake db:migrate</code>. All the tables got built as they should have. I assumed whatever was broken was fixed.</p>
  
  <p>So I went <code>rake db:migrate version=0</code>.... and again nothing happened. Tables still exist in the database where it should've gone back to being empty.</p>
  
  <p>Does anyone have any ideas? Have pretty much scratched a hole in my scalp here at this point.</p>
  
  <p>After manually dropping the database and running my migrations, <code>rake db:migrate version=0 --dry-run --trace</code> gives me the response:</p>
  
  <pre><code>** Invoke db:migrate (first_time)
  ** Invoke environment (first_time)
  ** Execute (dry run) environment
  ** Execute (dry run) db:migrate
  </code></pre>
  
  <p>My migrations at this point are all just replications of the RailsTutorial.org ones, which is what I've been working off until now as a learning exercise; they do all have self.down methods and they all work when I step it back one at a time.</p>
  
  <p>The only other thing that might be relevant is that I completed that tutorial on a different computer (my PC); I pushed it up to github and cloned it onto my Mac in order to use the tutorial as a starting point for my own work. The app does seem to run okay in my browser on the Mac (same as on the PC), although I've been following a myriad of tutorials to get the Rails environment (RVM) set up on the Mac for the first time and I've installed different gems to do so. Could my problem possibly stem from here?</p>
  
  <p>Thanks for any advice!</p>