instance method
change_column
Ruby on Rails 3.0.20
Since v2.2.3Signature
change_column(table_name, column_name, type, options = {})
Changes the column’s definition according to the new options. See TableDefinition#column for details of the options you can use.
Examples
change_column(:suppliers, :name, :string, :limit => 80) change_column(:accounts, :description, :text)
Parameters
-
table_namereq -
column_namereq -
typereq -
optionsopt = {}
Source
# File activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb, line 268
def change_column(table_name, column_name, type, options = {})
raise NotImplementedError, "change_column is not implemented"
end
Defined in activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb line 268
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveRecord::ConnectionAdapters::SchemaStatements