My version of rails is 4.0.0, my version of mysql is Ver 14.14 Distrib 5.7.9, for Win64 (x86_64). I am operating of an older version of rails as I was getting some clashes w
Did not have luck with the solutions above (My env: Rails 3.0.20, MySQL 5.7.13, Ruby 1.9.3p551). Was able to get around it by overwriting the ActiveRecord::ConnectionAdapters::ColumnDefinition
class. See below:
class ActiveRecord::ConnectionAdapters::ColumnDefinition
def sql_type
type.to_sym == :primary_key ? 'int(11) auto_increment PRIMARY KEY' : base.type_to_sql(type.to_sym, limit, precision, scale) rescue type
end
end
Stored this in config/initializers/column_definition.rb