drop and re-create MySQL database using a ruby script -


is there way drop , re-create database within ruby script? gem (dbi, mysql2) should use?

with dbi have problem cannot connect mysql server when database has not yet been created.

thank you

mysql2 work, have @ rake tasks come rails db:create etc

edit :

rails rake tasks create / drop dbs

https://github.com/rails/rails/blob/master/activerecord/lib/active_record/railties/databases.rake


Comments

Popular posts from this blog

mysql - How to insert just year and month into date field? -

mod rewrite - Doing external redirect. .htaccess NS flag not working. How to achieve similar results? -