Rails Migration To Update postgress array column
When writing a Rails migration to update a column that uses postgres array, you need to include the "array: true" param:
update_column :table_name, :col_name, :integer, array: true, null: false, default '{}'
Written by Dave Schwantes
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Migration
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#