I\'m using Rails 3.2 and have a migration that contains the code:
add_column :users, :gift_aid, :integer, :default => 2
# reset columns
User.reset_column_
this isn't needed on rails 6 (tested on 6.0.0beta3).
I tried both with update!(new_column: ...)
and update_all(new_column: ...)
I think this must be some kind of bug related to schema caching... this might work:
User.connection.schema_cache.clear!
User.reset_column_information
(for Rails 3.2.2)