@@ -43,7 +43,8 @@ Exact Match
43
43
Literal value queries return documents with an exact match to your query filter.
44
44
45
45
The following example specifies a query filter as a parameter to the ``mongoc_collection_find_with_opts()``
46
- function. The code returns all documents with a ``type`` field value of ``"movie"``.
46
+ function. The code returns all documents in which the value of the ``type`` field
47
+ is ``"movie"``.
47
48
48
49
.. io-code-block::
49
50
:copyable: true
@@ -78,8 +79,8 @@ To view a full list of comparison operators, see the :manual:`Comparison Query O
78
79
</reference/operator/query-comparison/>` guide in the MongoDB Server manual.
79
80
80
81
The following example specifies a comparison operator in a query filter as a
81
- parameter to the ``mongoc_collection_find_with_opts()`` function. The code returns all documents with a
82
- ``year`` field value greater than ``2015``.
82
+ parameter to the ``mongoc_collection_find_with_opts()`` function. The code returns all documents
83
+ in which the value of the ``year`` field is greater than ``2015``.
83
84
84
85
.. io-code-block::
85
86
:copyable: true
@@ -93,7 +94,7 @@ parameter to the ``mongoc_collection_find_with_opts()`` function. The code retur
93
94
.. output::
94
95
:visible: false
95
96
96
- { "_id" : { "$oid" : " ..." } , "title" : "The Masked Saint", "year" : { "$numberInt" : "2016" }, ... }
97
+ { "_id" : ..., "title" : "The Masked Saint", "year" : { "$numberInt" : "2016" }, ... }
97
98
98
99
Logical Operators
99
100
-----------------
@@ -111,7 +112,7 @@ To learn more about logical operators, see the :manual:`Logical Query Operators
111
112
112
113
The following example specifies a logical operator in a query filter as a
113
114
parameter to the ``mongoc_collection_find_with_opts()`` function. The code returns all
114
- documents with a ``year`` field value of ``1983`` **or** ``1985``.
115
+ documents in which the value of the ``year`` field is ``1983`` **or** ``1985``.
115
116
116
117
.. io-code-block::
117
118
:copyable: true
@@ -125,11 +126,11 @@ documents with a ``year`` field value of ``1983`` **or** ``1985``.
125
126
.. output::
126
127
:visible: false
127
128
128
- { "_id" : { "$oid" : " ..." } , "title" : "Amityville 3-D", "year" : { "$numberInt" : "1983" }, ... }
129
- { "_id" : { "$oid" : " ..." } , "title" : "Barefoot Gen", "year" : { "$numberInt" : "1983" }, ... }
130
- { "_id" : { "$oid" : " ..." } , "title" : "Betrayal", "year" : { "$numberInt" : "1983" }, ... }
131
- { "_id" : { "$oid" : " ..." } , "title" : "You're a Good Man, Charlie Brown", "year" : { "$numberInt" : "1985" }, ... }
132
- { "_id" : { "$oid" : " ..." } , "title" : "Yes: 9012 Live", "year" : { "$numberInt" : "1985" }, ... }
129
+ { "_id" : ..., "title" : "Amityville 3-D", "year" : { "$numberInt" : "1983" }, ... }
130
+ { "_id" : ..., "title" : "Barefoot Gen", "year" : { "$numberInt" : "1983" }, ... }
131
+ { "_id" : ..., "title" : "Betrayal", "year" : { "$numberInt" : "1983" }, ... }
132
+ { "_id" : ..., "title" : "You're a Good Man, Charlie Brown", "year" : { "$numberInt" : "1985" }, ... }
133
+ { "_id" : ..., "title" : "Yes: 9012 Live", "year" : { "$numberInt" : "1985" }, ... }
133
134
...
134
135
135
136
Array Operators
@@ -146,8 +147,8 @@ To learn more about array operators, see the :manual:`Array Query Operators
146
147
</reference/operator/query-array/>` guide in the MongoDB Server manual.
147
148
148
149
The following example specifies an array operator in a query filter as a
149
- parameter to the ``mongoc_collection_find_with_opts()`` function. The code returns all documents with a
150
- ``genres`` array field containing exactly ``2`` elements.
150
+ parameter to the ``mongoc_collection_find_with_opts()`` function. The code returns all
151
+ documents in which the value of the ``genres`` array field contains exactly ``2`` elements.
151
152
152
153
.. io-code-block::
153
154
:copyable: true
@@ -161,11 +162,11 @@ parameter to the ``mongoc_collection_find_with_opts()`` function. The code retur
161
162
.. output::
162
163
:visible: false
163
164
164
- { "_id" : { "$oid" : " ..." } , "genres" : [ "Comedy", "Romance" ], "title" : "The Devil to Pay!", ... }
165
- { "_id" : { "$oid" : " ..." } , "genres" : [ "Crime", "Drama" ], "title" : "Traffic in Souls", ... }
166
- { "_id" : { "$oid" : " ..." } , "genres" : [ "Comedy", "Short" ], "title" : "High and Dizzy", ... }
167
- { "_id" : { "$oid" : " ..." } , "genres" : [ "Comedy", "Short" ], "title" : "Now or Never", ... }
168
- { "_id" : { "$oid" : " ..." } , "genres" : [ "Drama", "Romance" ], "title" : "A Woman of Paris: A Drama of Fate", ... }
165
+ { "_id" : ..., "genres" : [ "Comedy", "Romance" ], "title" : "The Devil to Pay!", ... }
166
+ { "_id" : ..., "genres" : [ "Crime", "Drama" ], "title" : "Traffic in Souls", ... }
167
+ { "_id" : ..., "genres" : [ "Comedy", "Short" ], "title" : "High and Dizzy", ... }
168
+ { "_id" : ..., "genres" : [ "Comedy", "Short" ], "title" : "Now or Never", ... }
169
+ { "_id" : ..., "genres" : [ "Drama", "Romance" ], "title" : "A Woman of Paris: A Drama of Fate", ... }
169
170
...
170
171
171
172
Element Operators
@@ -192,11 +193,11 @@ documents that have a ``num_mflix_comments`` field.
192
193
.. output::
193
194
:visible: false
194
195
195
- { "_id" : { "$oid" : " ..." } , "num_mflix_comments" : { "$numberInt" : "0" }, "title" : "The Park Is Mine", ...}
196
- { "_id" : { "$oid" : " ..." } , "num_mflix_comments" : { "$numberInt" : "1" }, "title" : "The Good Father", ... }
197
- { "_id" : { "$oid" : " ..." } , "num_mflix_comments" : { "$numberInt" : "0" }, "title" : "Alpine Fire", ... }
198
- { "_id" : { "$oid" : " ..." } , "num_mflix_comments" : { "$numberInt" : "1" }, "title" : "Huang jia shi jie", ... }
199
- { "_id" : { "$oid" : " ..." } , "num_mflix_comments" : { "$numberInt" : "0" }, "title" : "Twenty Years Later", ... }
196
+ { "_id" : ..., "num_mflix_comments" : { "$numberInt" : "0" }, "title" : "The Park Is Mine", ...}
197
+ { "_id" : ..., "num_mflix_comments" : { "$numberInt" : "1" }, "title" : "The Good Father", ... }
198
+ { "_id" : ..., "num_mflix_comments" : { "$numberInt" : "0" }, "title" : "Alpine Fire", ... }
199
+ { "_id" : ..., "num_mflix_comments" : { "$numberInt" : "1" }, "title" : "Huang jia shi jie", ... }
200
+ { "_id" : ..., "num_mflix_comments" : { "$numberInt" : "0" }, "title" : "Twenty Years Later", ... }
200
201
...
201
202
202
203
Evaluation Operators
@@ -218,7 +219,7 @@ To view a full list of evaluation operators, see the :manual:`Evaluation Query O
218
219
219
220
The following example specifies an evaluation operator in a query filter as a
220
221
parameter to the ``mongoc_collection_find_with_opts()`` function. The code uses a regular
221
- expression to return all documents with a ``title`` field value that has at least two
222
+ expression to return all documents in which the value of the ``title`` field has at least two
222
223
consecutive ``"p"`` characters.
223
224
224
225
.. io-code-block::
@@ -233,11 +234,11 @@ consecutive ``"p"`` characters.
233
234
.. output::
234
235
:visible: false
235
236
236
- { "_id" : { "$oid" : " ..." } , "title" : "He Who Gets Slapped", ... }
237
- { "_id" : { "$oid" : " ..." } , "title" : "David Copperfield", ... }
238
- { "_id" : { "$oid" : " ..." } , "title" : "Applause", ... }
239
- { "_id" : { "$oid" : " ..." } , "title" : "Skippy", ... }
240
- { "_id" : { "$oid" : " ..." } , "title" : "This Happy Breed", ... }
237
+ { "_id" : ..., "title" : "He Who Gets Slapped", ... }
238
+ { "_id" : ..., "title" : "David Copperfield", ... }
239
+ { "_id" : ..., "title" : "Applause", ... }
240
+ { "_id" : ..., "title" : "Skippy", ... }
241
+ { "_id" : ..., "title" : "This Happy Breed", ... }
241
242
...
242
243
243
244
Additional Information
@@ -246,7 +247,7 @@ Additional Information
246
247
To learn more about querying documents, see the :manual:`Query Documents
247
248
</tutorial/query-documents/>` guide in the MongoDB Server manual.
248
249
249
- To learn more about retrieving documents with the {+driver-short+}, see
250
+ To learn more about using the {+driver-short+} to retrieve documents , see
250
251
:ref:`c-retrieve`.
251
252
252
253
API Documentation
0 commit comments