1class CreateProducts < ActiveRecord::Migration[5.0] 2 def change 3 create_table :products do |t| 4 t.string :name 5 t.text :description 6 end 7 end 8end
rails generate migration
rails db:migrate
rails db:rollback
rails db:reset
rake db:create_migration
rake db:migrate
rake db:rollback
rake db:reset