Closed crooy closed 12 years ago
Took me a while, but I realized this error was caused by acts-as-taggable-on and not this plugin. Nevertheless, I kinda fixed it by changing:
add_index :taggings, :tag_id
add_index :taggings, [:taggable_id, :taggable_type, :context]
into
add_index :taggings, :tag_id
add_index :taggings, :taggable_id
add_index :taggings, :taggable_type
add_index :taggings, :context
Any queries on the three columns should result in a merge of the three indexes, and a negligible loss of performance for the query.
by the way, more people appear to have this issue : http://stackoverflow.com/questions/3489041/mysqlerror-specified-key-was-too-long-max-key-length-is-1000-bytes
The add_index is part of acts_as_taggable, right? So it's not something I can actually fix. But thanks for figuring this out, I'll add it to the readme.
When calling rake db:migrate I get this error. If I'm not mistaking this is because the index is over a couple of varchar(255) utf8 columns.