Convert Ruby ActiveRecord Schema to SQL syntax -


i haven't used ruby trying learn. found 'schema.db' file looks generated active record module.

i trying figure out how convert file sql can import database?

active record generate schema.rb , represents current state of database (useful getting quick idea of attributes each model has).

it used when deploying new instances of app, rather replaying whole migration history (and how test database created)

as example, here's how can deploy production database:

rails_env=production rake db:create db:load 

Comments

Popular posts from this blog

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

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