aboutsummaryrefslogtreecommitdiffstats
path: root/guides
diff options
context:
space:
mode:
authorAlex Handley <ahandley@me.com>2016-04-16 13:26:05 +0100
committerAlex Handley <ahandley@me.com>2016-04-16 21:32:22 +0100
commitd9565811f075273fbc3318af173fe4a21e14ae58 (patch)
tree4d6b308b239ef97525a01aa494e912232b04080f /guides
parentfa8602656edbf879430fffefc5efa11d253da003 (diff)
downloadrails-d9565811f075273fbc3318af173fe4a21e14ae58.tar.gz
rails-d9565811f075273fbc3318af173fe4a21e14ae58.tar.bz2
rails-d9565811f075273fbc3318af173fe4a21e14ae58.zip
[ci skip] docs for add_references index option
- Add link for finding the addional options for index. - Add example for unique index as this is a common requirement. - Add link in guide for index options.
Diffstat (limited to 'guides')
-rw-r--r--guides/source/active_record_migrations.md3
1 files changed, 2 insertions, 1 deletions
diff --git a/guides/source/active_record_migrations.md b/guides/source/active_record_migrations.md
index cd6b7fdd67..31f6f26b2a 100644
--- a/guides/source/active_record_migrations.md
+++ b/guides/source/active_record_migrations.md
@@ -246,7 +246,8 @@ class AddUserRefToProducts < ActiveRecord::Migration[5.0]
end
```
-This migration will create a `user_id` column and appropriate index.
+This migration will create a `user_id` column and appropriate index.
+For more `add_reference` options, visit the [API documentation](http://api.rubyonrails.org/classes/ActiveRecord/ConnectionAdapters/SchemaStatements.html#method-i-add_reference).
There is also a generator which will produce join tables if `JoinTable` is part of the name: