Rails 4 pgsql add_index with type GIN or GiST June 6, 2023 by Tarik In Rails 4, you can now do something like this in a migration: add_index :products, :data, using: :gin