simple_hashtag
simple_hashtag copied to clipboard
Index name is too long
$ rails db:migrate
== 20170401172016 CreateSimpleHashtagHashtags: migrating ======================
-- create_table(:simple_hashtag_hashtags)
-> 0.0342s
== 20170401172016 CreateSimpleHashtagHashtags: migrated (0.0347s) =============
== 20170401172017 CreateSimpleHashtagHashtaggings: migrating ==================
-- create_table(:simple_hashtag_hashtaggings)
rails aborted!
StandardError: An error has occurred, all later migrations canceled:
Index name 'index_simple_hashtag_hashtaggings_on_hashtaggable_type_and_hashtaggable_id' on table 'simple_hashtag_hashtaggings' is too long; the limit is 64 characters
app_root/db/migrate/20170401172017_create_simple_hashtag_hashtaggings.rb:4:in `change'
bin/rails:4:in `require'
bin/rails:4:in `<main>'
ArgumentError: Index name 'index_simple_hashtag_hashtaggings_on_hashtaggable_type_and_hashtaggable_id' on table 'simple_hashtag_hashtaggings' is too long; the limit is 64 characters
app_root/db/migrate/20170401172017_create_simple_hashtag_hashtaggings.rb:4:in `change'
bin/rails:4:in `require'
bin/rails:4:in `<main>'
Tasks: TOP => db:migrate
(See full trace by running task with --trace)
I forgot how I fixed this error the first time. There's definitely too much going on with the index.
@RailsCod3rFuture I created a pull request #23