Purge or recreate a Ruby on Rails database

前端 未结 19 1252
清酒与你
清酒与你 2020-11-28 17:01

I have a dev Ruby on Rails database full of data. I want to delete everything and rebuild the database. I\'m thinking of using something like:

rake db:recrea         


        
19条回答
  •  抹茶落季
    2020-11-28 17:24

    According to Rails guide, this one liner should be used because it would load from the schema.rb instead of reloading the migration files one by one:

    rake db:reset
    

提交回复
热议问题