Change comments relation to use text data type for attribute text

This commit is contained in:
Ralf Teusner
2016-05-12 16:23:40 +02:00
parent a2a902796a
commit 7ec3443adf
2 changed files with 12 additions and 7 deletions

View File

@@ -0,0 +1,10 @@
class ChangeCommentTextAttributeToTextDatatype < ActiveRecord::Migration
def up
change_column :comments, :text, :text
end
def down
# This might cause trouble if you have strings longer
# than 255 characters.
change_column :comments, :text, :string
end
end