What is the mysql equivalent to heroku pg:reset DATABASE?

Hey Everyone,

I was just wondering if anyone knew the mysql equivalent to $ heroku pg:reset DATABASE.

Thank you

You can use rake db:reset in your Rails root, with the correct RAILS_ENV= set in the same line. Your database user (as configured in the database.yml file) will have to have the authority to drop the database.

Walter

Thank you Walter. What if I am performing the task from a command line?

That is the command-line:

cd /path/to/your/app rake db:reset RAILS_ENV=production (or whatever)

That will do the whole job. It will drop the database, re-create it, and build up all the tables from the schema.rb.

Walter

Do what Walter said

in terms of Rails the two are interchangeable.