aboutsummaryrefslogtreecommitdiffstats
path: root/guides
diff options
context:
space:
mode:
authorRichard Schneeman <richard.schneeman+no-recruiters@gmail.com>2018-08-11 14:49:59 -0500
committerGitHub <noreply@github.com>2018-08-11 14:49:59 -0500
commit141f50ef9ee6ce26820549e9f5b4629ddee182ce (patch)
tree5a96ed0a7bea7697dba593537ef354019400af08 /guides
parent317efa5c3593b70e9cc9a2fcb67488a302b71731 (diff)
parent847e6915268e1ff1a1aeb5c48c7d9af01e2ff383 (diff)
downloadrails-141f50ef9ee6ce26820549e9f5b4629ddee182ce.tar.gz
rails-141f50ef9ee6ce26820549e9f5b4629ddee182ce.tar.bz2
rails-141f50ef9ee6ce26820549e9f5b4629ddee182ce.zip
Merge pull request #33563 from lzap/foreign-key-note-doc
ActiveRecord Guide - sqlite3 foreign keys note
Diffstat (limited to 'guides')
-rw-r--r--guides/source/active_record_migrations.md4
1 files changed, 4 insertions, 0 deletions
diff --git a/guides/source/active_record_migrations.md b/guides/source/active_record_migrations.md
index cfa444fda0..be5af133ff 100644
--- a/guides/source/active_record_migrations.md
+++ b/guides/source/active_record_migrations.md
@@ -491,6 +491,10 @@ NOTE: Active Record only supports single column foreign keys. `execute` and
`structure.sql` are required to use composite foreign keys. See
[Schema Dumping and You](#schema-dumping-and-you).
+NOTE: At this time, only the mysql, mysql2 and postgresql adapters support
+foreign keys. Implementation for sqlite3 is partial, keys are created for new
+tables but not for existing tables via `ALTER TABLE` statement.
+
Removing a foreign key is easy as well:
```ruby