aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord
diff options
context:
space:
mode:
authorNate Pinsky <mrpinsky@users.noreply.github.com>2018-08-27 19:13:06 -0700
committerRafael França <rafaelmfranca@gmail.com>2018-08-27 21:13:06 -0500
commit626958ce98aece8c3ac6576cb92d24423a9fadaf (patch)
tree880a4bc9b56d6ab6b4103aebd148b7829dc020b3 /activerecord
parent3218a662818a52bd20eb93ee5468e62bdc9ccdf6 (diff)
downloadrails-626958ce98aece8c3ac6576cb92d24423a9fadaf.tar.gz
rails-626958ce98aece8c3ac6576cb92d24423a9fadaf.tar.bz2
rails-626958ce98aece8c3ac6576cb92d24423a9fadaf.zip
Add documentation for `:collation` column option (#33733)
* Add documentation for `:collation` option The table definition supports a `:collation` option for string and text columns, but this is not documented anywhere that I could find. I'm not sure if the "If not specified" part is accurate. From [this PR](https://github.com/rails/rails/commit/1515c4d98da3f730ef971fa5a13cad828bd9bef4), it looks like it passes `nil` and lets the database handle the collation, but I'm happy to change it if I misread the code. [ci skip] * FIX remove whitespace [Nate Pinsky + Rafael Mendonça França]
Diffstat (limited to 'activerecord')
-rw-r--r--activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb3
1 files changed, 3 insertions, 0 deletions
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 4702de1964..84ea7a0c33 100644
--- a/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb
+++ b/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb
@@ -522,6 +522,9 @@ module ActiveRecord
# Specifies the precision for the <tt>:decimal</tt> and <tt>:numeric</tt> columns.
# * <tt>:scale</tt> -
# Specifies the scale for the <tt>:decimal</tt> and <tt>:numeric</tt> columns.
+ # * <tt>:collation</tt> -
+ # Specifies the collation for a <tt>:string</tt> or <tt>:text</tt> column. If not specified, the
+ # column will have the same collation as the table.
# * <tt>:comment</tt> -
# Specifies the comment for the column. This option is ignored by some backends.
#