X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/c533fb4b7430c5c9e194bde7a047b7479c758130..31a031be26408b7cb2487203a2bfd8aa5eb51a3e:/db/migrate/20121203124841_change_note_address_to_inet.rb diff --git a/db/migrate/20121203124841_change_note_address_to_inet.rb b/db/migrate/20121203124841_change_note_address_to_inet.rb new file mode 100644 index 000000000..e4e53e35a --- /dev/null +++ b/db/migrate/20121203124841_change_note_address_to_inet.rb @@ -0,0 +1,9 @@ +class ChangeNoteAddressToInet < ActiveRecord::Migration + def up + execute "ALTER TABLE note_comments ALTER COLUMN author_ip TYPE inet USING CAST(author_ip AS inet)" + end + + def down + change_column :note_comments, :author_ip, :string + end +end