Skip to content

Commit 651fd1b

Browse files
authored
add note about document keys using simple collation (#6153) (#6204)
* add note about document keys using simple collation * fix link
1 parent e0ef5fc commit 651fd1b

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

source/includes/extracts-collation.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,13 @@ content: |-
168168
.. code-block:: javascript
169169
170170
db.myColl.find( { score: 5, category: "cafe" } )
171+
172+
.. important::
171173
174+
Matches against document keys, including embedded document keys,
175+
use simple binary comparison. This means that a query for a key
176+
like "foo.bár" will not match the key "foo.bar", regardless of the value you
177+
set for the :ref:`strength <collation-parameter-strength>` parameter.
172178
173179
---
174180
ref: collation-index

source/reference/collation.txt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,13 +57,15 @@ parameters and the locales they are associated with, see
5757
To specify simple binary comparison, specify ``locale`` value of
5858
``"simple"``.
5959

60-
60+
6161

6262
* - ``strength``
6363

6464
- integer
6565

66-
- Optional. The level of comparison to perform.
66+
- .. _collation-parameter-strength:
67+
68+
Optional. The level of comparison to perform.
6769
Corresponds to `ICU Comparison Levels
6870
<http://userguide.icu-project.org/collation/concepts#TOC-Comparison-Levels>`_.
6971
Possible values are:

0 commit comments

Comments
 (0)