@@ -58,7 +58,7 @@ Specify a Collation
58
58
59
59
To specify a collation, create a ``Collation`` object. You must define the ``Locale`` field
60
60
of the ``Collation`` object; all other fields are optional. For example, the following code
61
- snippet specifies a ``Collation`` object with the ``"en_US"`` locale collation:
61
+ example specifies a ``Collation`` object with the ``"en_US"`` locale collation:
62
62
63
63
.. code-block:: go
64
64
@@ -100,7 +100,7 @@ Use the Default Collation Example
100
100
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
101
101
102
102
If you call an operation that uses a collation on the ``books`` collection, the operation
103
- will now use the default collation specified in the :ref:`golang-create-collection`.
103
+ uses the default collation specified in the :ref:`golang-create-collection`.
104
104
105
105
Assume the ``books`` collection contains the following documents:
106
106
@@ -173,8 +173,8 @@ doesn't perform the ordering for sorting operations in-memory.
173
173
174
174
To use the index in an operation, your operation must use the same collation as the one
175
175
specified in the index. Additionally, ensure that the operation is covered by the index that
176
- contains the collation. Set a collation through an ``IndexOptions`` object and call the
177
- ``CreateOne()`` method with your options object as an argument .
176
+ contains the collation. Set a collation through an ``IndexOptions`` object and pass this object
177
+ as an argument to the ``CreateOne()`` method.
178
178
179
179
Example
180
180
~~~~~~~
@@ -234,8 +234,8 @@ Example
234
234
You can use operations that support collation to update and query documents in the
235
235
``books`` collection.
236
236
237
- The following example uses the ``Find()`` method to return documents with ``length``
238
- values greater than ``"1000"``. The ``NumericOrdering`` collation field has a value of
237
+ The following example uses the ``Find()`` method to return documents in which the ``length``
238
+ value is greater than ``"1000"``. The ``NumericOrdering`` collation field has a value of
239
239
``true`` to ensure that values are sorted in numerical order rather than alphabetical
240
240
order:
241
241
0 commit comments