Gør følgende:
- omdøb kolonne A
- opret den nye kolonne B som dato
- flyt data fra A til B
- fjern A
Med andre ord
def self.up
rename_column :contacts, :date_entered, :date_entered_string
add_column :contacts, :date_entered, :date
Contact.reset_column_information
Contact.find_each { |c| c.update_attribute(:date_entered, c.date_entered_string) }
remove_column :contacts, :date_entered_string
end