clarion/db/migrate/20161011005420_add_descriptions_for_all_events.rb

12 lines
206 B
Ruby
Raw Normal View History

2016-10-11 03:55:49 +03:00
class Event < ActiveRecord::Base
end
class AddDescriptionsForAllEvents < ActiveRecord::Migration
def up
Event.where(description: [nil, '']).update_all(description: 'n/a')
end
def down
end
end