Last active
January 22, 2016 16:41
-
-
Save miligraf/c626017ca0b48d5e5f3f to your computer and use it in GitHub Desktop.
Ruby on Rails database table index naming convention
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Rails, or Active Record in this case, only identifies indexes with the following name pattern: | |
index_<table_name>_on_<column_name> | |
If name is different than that, it will completely ignore the index and won't use it. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment