What you can do is add a column, update all the records in the table with the desired value, and then change it to not allow zeros.
def self.up add_column :reminders, :active, :boolean, :default => true Reminder.update_all( "active = ?", true ) change_column :reminders, :active, :boolean, :default => true, :null => :false end
source share