hstore indexes not saved to schema.rb correctly.
The hstore indexes are not saved to schema.rb correctly..
instead of saving an add_hstore_index line it simply creates an add_index line, thus the 'gin' index isn't created.
A related issue is that the add_hstore_index :table, :column, :type => :gin doesn't work. (the AR method add_index_options doesn't support a :type option, only :name and :unique).
We are running Rails 3.2.x (going to 4.0 right now isn't an option.. though it's on our roadmap)
You could work around using an SQL schema for now. If yu want to keep the schema.rb you can check this gem (which adds the index kind feature): https://github.com/lomba/schema_plus.
Is this something that can be easily added to this gem? Or does it require monkey'ing w/ the core ActiveRecord?
I'm not sure, I suppose it does need monkey patching though.
I'm looking at the schema_plus.. it looks interesting..
(I could maybe sneak in some views and SPs to make reporting easier.. WOOT!)