Actions
Refactor #14025
closedSpecify string column limits
Pull request:
Fixed in Releases:
Found in Releases:
Description
In Rails 4.2 the default limit for PostgreSQL and SQLite adapters
changes to unlimited from 255 characters. MySQL remains at 255 chars.
Existing migrations should be changed to specify the length, e.g.
t.column :name, :string, :null => false, :limit => 255
This will ensure that the schema generated on a new installation exactly
matches the schema from an old installation, so there won't be varying
versions of the schema in the wild.
Actions