diff options
author | Grey Baker <greysteil@gmail.com> | 2015-04-13 01:32:51 +0200 |
---|---|---|
committer | Grey Baker <greysteil@gmail.com> | 2015-04-13 09:33:48 +0200 |
commit | e91c4339e4d8967f3d8e9eaf1f82bbc113bc69c1 (patch) | |
tree | 01a08b36acf94aea7b879b3f1fcbfc811533914e /activerecord | |
parent | 86ba051486ec0b91ecb403f21a2c384cf6b926dd (diff) | |
download | rails-e91c4339e4d8967f3d8e9eaf1f82bbc113bc69c1.tar.gz rails-e91c4339e4d8967f3d8e9eaf1f82bbc113bc69c1.tar.bz2 rails-e91c4339e4d8967f3d8e9eaf1f82bbc113bc69c1.zip |
Document that partial indexes are only supported by Postgres and SQLite.
Fixes #18106
Diffstat (limited to 'activerecord')
-rw-r--r-- | activerecord/CHANGELOG.md | 6 | ||||
-rw-r--r-- | activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb | 2 |
2 files changed, 8 insertions, 0 deletions
diff --git a/activerecord/CHANGELOG.md b/activerecord/CHANGELOG.md index 904ac5c26a..1af9a57e4f 100644 --- a/activerecord/CHANGELOG.md +++ b/activerecord/CHANGELOG.md @@ -1,3 +1,9 @@ +* Add note that partial indexes are only supported by Postgres and SQLite. + + Fixes #18106 + + *Grey Baker* + * Fixed a bug where uniqueness validations would error on out of range values, even if an validation should have prevented it from hitting the database. diff --git a/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb b/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb index 466b076571..ecb4868c13 100644 --- a/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb +++ b/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb @@ -537,6 +537,8 @@ module ActiveRecord # # CREATE UNIQUE INDEX index_accounts_on_branch_id_and_party_id ON accounts(branch_id, party_id) WHERE active # + # Note: Partial indexes are only supported for PostgreSQL and SQLite 3.8.0+. + # # ====== Creating an index with a specific method # # add_index(:developers, :name, using: 'btree') |