rake db:reset
rake db:migrate
This will reset your database and reload your current schema with all.
rake db:drop
rake db:create
rake db:migrate
41 down vote accepted
To drop the database:
heroku pg:reset
To recreate the database with nothing in it:
heroku rake db:migrate
To populate the database with your seed data:
heroku rake db:seed
You can combine the last two into one action by executing this:
heroku rake db:setup
OR
To drop the database:
$ heroku pg:reset SHARED_DATABASE --confirm NAME_OF_THE_APP
To recreate the database:
$ heroku run rake db:migrate
To seed the database:
$ heroku run rake db:seed
**Final step
$ heroku restart
No comments:
Post a Comment