aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbogdanvlviv <bogdanvlviv@gmail.com>2018-08-12 14:56:23 +0300
committerbogdanvlviv <bogdanvlviv@gmail.com>2018-08-12 22:25:11 +0300
commite3ae53f92ca4b5349b7ca54e814063299de03bf0 (patch)
tree74d3d308bc5f4e204fc6ab9ce916c00590363e2d
parentbddab1fc864078dd1247bd8c2dd9668e0ff25f26 (diff)
downloadrails-e3ae53f92ca4b5349b7ca54e814063299de03bf0.tar.gz
rails-e3ae53f92ca4b5349b7ca54e814063299de03bf0.tar.bz2
rails-e3ae53f92ca4b5349b7ca54e814063299de03bf0.zip
Clarify note that SQLite3 adapter doesn't support `add_foreign_key` [ci skip]
Context https://github.com/rails/rails/pull/33563#discussion_r208891486. Follow up #33563
-rw-r--r--guides/source/active_record_migrations.md5
1 files changed, 2 insertions, 3 deletions
diff --git a/guides/source/active_record_migrations.md b/guides/source/active_record_migrations.md
index e2359a35f1..9446441b20 100644
--- a/guides/source/active_record_migrations.md
+++ b/guides/source/active_record_migrations.md
@@ -491,9 +491,8 @@ 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.
+NOTE: The SQLite3 adapter doesn't support `add_foreign_key` since SQLite supports
+only [a limited subset of ALTER TABLE](https://www.sqlite.org/lang_altertable.html).
Removing a foreign key is easy as well: