我有这个简单的迁移:
class AddUpdateStatusToProducts < ActiveRecord::Migration
def self.up
add_column :products, :update_status, :integer, :default => 0
end
end
rake db:migrate
产生这个错误:
rake aborted!
/Users/adam/rubydev/project_name/lib/tasks/scheduler.rake:90: syntax error, unexpected $end, expecting keyword_end
问题出在哪里?表名正确,迁移的语法也应该是...