ratyrate icon indicating copy to clipboard operation
ratyrate copied to clipboard

average_cache_migration generates index name that is too long for Postgres

Open yourtallness opened this issue 7 years ago • 1 comments

The following statement generates an index name upwards of 63 characters long which Postgres errors out on.

add_index :average_caches, [:rater_id, :rateable_id, :rateable_type]

I would recommend explicit naming of the index to avoid this issue.

yourtallness avatar Mar 01 '17 09:03 yourtallness

add_index :average_caches, [:rater_id, :rateable_id] add_index :average_caches, [:rateable_type]

JIuc75Rus avatar Mar 04 '17 04:03 JIuc75Rus