@@ -129,7 +129,8 @@ Core Explain Output
129
129
130
130
.. data:: cursor
131
131
132
- Specifies the type of cursor used in the query operation:
132
+ :data:`cursor` is a string value that returns the type of cursor
133
+ used in the query operation:
133
134
134
135
- ``BasicCursor`` indicates use of full collection scan.
135
136
@@ -142,53 +143,56 @@ Core Explain Output
142
143
143
144
.. data:: isMultiKey
144
145
145
- A boolean, that specifies if the index used in this query is a
146
- :ref:`multikey index <index-type-multikey>` on a field that holds
147
- an array.
146
+ :data:`isMultiKey` is a boolean value that returns ``true`` if the
147
+ index used in this query is a :ref:`multikey index
148
+ <index-type-multikey>` on a field that holds an array.
148
149
149
150
.. data:: n
150
151
151
- Specifies the number of documents that match the query selection
152
- criteria.
152
+ :data:`n` is a number value that returns the number of documents
153
+ that match the query selection criteria.
153
154
154
155
.. data:: nscannedObjects
155
156
156
- Specifies the total number of documents scanned during the query.
157
- The :data:`nscannedObjects` may be lower than :data:`nscanned`, such
158
- as if the index is a covered index.
157
+ :data:`nscannedObjects` is a number value that returns the total
158
+ number of documents scanned during the query. The
159
+ :data:`nscannedObjects` may be lower than :data:`nscanned`, such as
160
+ if the index is a covered index.
159
161
160
162
.. data:: nscanned
161
163
162
- Specifies the total number of documents or index entries scanned
163
- during the database operation. You want :data:`n` and
164
- :data:`nscanned` to be close in value as possible. The
165
- :data:`nscanned` value may be higher than the
164
+ :data:`nscanned` is a number value that returns the total number of
165
+ documents or index entries scanned during the database operation.
166
+ You want :data:`n` and :data:` nscanned` to be close in value as
167
+ possible. The :data:`nscanned` value may be higher than the
166
168
:data:`nscannedObjects` value, such as if the index is a covered
167
169
index.
168
170
169
171
.. data:: nscannedObjectsAllPlans
170
172
171
173
.. versionadded:: 2.2
172
174
173
- Specifies the total number of documents scanned for all query plans
174
- during the database operation.
175
+ :data:`nscannedObjectsAllPlans` is a number value that returns the
176
+ total number of documents scanned for all query plans during the
177
+ database operation.
175
178
176
179
.. data:: nscannedAllPlans
177
180
178
181
.. versionadded:: 2.2
179
182
180
- Specifies the total number of documents or index entries scanned for
181
- all query plans during the database operation.
183
+ :data:`nscannedAllPlans` is a number value that returns the total
184
+ number of documents or index entries scanned for all query plans
185
+ during the database operation.
182
186
183
187
.. data:: scanAndOrder
184
188
185
189
.. versionadded:: 2.2
186
190
187
191
:data:`scanAndOrder` is a boolean value that returns ``true`` when
188
- the query cannot use the index for returning sorted results.
192
+ the query ** cannot** use the index for returning sorted results.
189
193
190
- When ``false`` MongoDB must sort documents retrieving the documents
191
- using either an index cursor or by cursor that scans the entire
194
+ When ``true``, MongoDB must sort the documents after it retrieves
195
+ them from either an index cursor or a cursor that scans the entire
192
196
collection.
193
197
194
198
.. data:: indexOnly
@@ -200,24 +204,25 @@ Core Explain Output
200
204
201
205
.. data:: nYields
202
206
203
- Specifies the number of times this query yielded the read lock to
204
- allow waiting writes execute.
207
+ :data:`nYields` is a number value that returns the number of times
208
+ this query yielded the read lock to allow waiting writes execute.
205
209
206
210
.. data:: nChunkSkips
207
211
208
- Specifies the number of documents skipped because of active chunk
209
- migrations in a sharded system. Typically this will be zero. A
210
- number greater than zero is ok, but indicates a little bit of
211
- inefficiency.
212
+ :data:`nChunkSkips` is a number value that returns the number of
213
+ documents skipped because of active chunk migrations in a sharded
214
+ system. Typically this will be zero. A number greater than zero is
215
+ ok, but indicates a little bit of inefficiency.
212
216
213
217
.. data:: millis
214
218
215
- Specifies the number of milliseconds to complete the query.
219
+ :data:`millis` is a number value that returns the time in
220
+ milliseconds to complete the query.
216
221
217
222
.. data:: indexBounds
218
223
219
- Specifies the lower and upper index key bounds. This field
220
- resembles one of the following:
224
+ :data:`indexBounds` is a document that contains the lower and upper
225
+ index key bounds. This field resembles one of the following:
221
226
222
227
.. code-block:: javascript
223
228
@@ -234,24 +239,25 @@ Core Explain Output
234
239
235
240
.. data:: allPlans
236
241
237
- Specifies the list of plans the query optimizer runs in order to
238
- select the index for the query. Displays only when the ``<verbose>``
239
- parameter to :method:`explain() <cursor.explain()>` is
240
- ``true`` or ``1``.
242
+ :data:`allPlans` is an array value that returns the list of plans
243
+ the query optimizer runs in order to select the index for the query.
244
+ Displays only when the ``<verbose>`` parameter to :method:`explain()
245
+ <cursor.explain()>` is ``true`` or ``1``.
241
246
242
247
.. data:: oldPlan
243
248
244
249
.. versionadded:: 2.2
245
250
246
- Specifies the previous plan selected by the query optimizer for the
247
- query. Displays only when the ``<verbose>`` parameter to
248
- :method:`explain() <cursor.explain()>` is ``true`` or ``1``.
251
+ :data:`oldPlan` is a document value that returns the previous plan
252
+ selected by the query optimizer for the query. Displays only when
253
+ the ``<verbose>`` parameter to :method:`explain()
254
+ <cursor.explain()>` is ``true`` or ``1``.
249
255
250
256
.. data:: server
251
257
252
258
.. versionadded:: 2.2
253
259
254
- Specifies the MongoDB server.
260
+ :data:`server` is a string value that returns the MongoDB server.
255
261
256
262
.. _explain-output-field-or-clauses:
257
263
@@ -260,10 +266,10 @@ Core Explain Output
260
266
261
267
.. data:: clauses
262
268
263
- Contains the :ref:`explain-output-fields-core` information for each
264
- clause of the :operator:`$or` expression. :data:`classes` is only
265
- included when the clauses in the :operator:`$or` expression use
266
- indexes.
269
+ :data:`clauses` is an array value that returns the
270
+ :ref:`explain-output-fields-core` information for each clause of the
271
+ :operator:`$or` expression. :data:`classes` is only included when
272
+ the clauses in the :operator:`$or` expression use indexes.
267
273
268
274
.. _explain-output-fields-sharded-collection:
269
275
@@ -272,31 +278,35 @@ Sharded Collections Output
272
278
273
279
.. data:: clusteredType
274
280
275
- Describes the access pattern for shards. The value is:
281
+ :data:`clusteredType` is a string value that returns the access
282
+ pattern for shards. The value is:
276
283
277
284
- ``ParallelSort``, if the :program:`mongos` queries shards in parallel.
278
285
279
286
- ``SerialServer``, if the :program:`mongos` queries shards sequentially.
280
287
281
288
.. data:: shards
282
289
283
- Specifies the shards accessed during the query and individual
284
- :ref:`explain-output-fields-core` for each shard.
290
+ :data:`shards` is a document value that contains the shards accessed
291
+ during the query and individual :ref:`explain-output-fields-core`
292
+ for each shard.
285
293
286
294
.. data:: millisShardTotal
287
295
288
- Specifies the total time in milliseconds for the query to run on the
289
- shards.
296
+ :data:`millisShardTotal` is a number value that returns the total
297
+ time in milliseconds for the query to run on the shards.
290
298
291
299
.. data:: millisShardAvg
292
300
293
- Specifies the average time in millisecond for the query to run on
294
- each shard.
301
+ :data:`millisShardAvt` is a number value that returns the average
302
+ time in millisecond for the query to run on each shard.
295
303
296
304
.. data:: numQueries
297
305
298
- Specifies the total number of queries executed.
306
+ :data:`numQueries` is a number value that returns the total number
307
+ of queries executed.
299
308
300
309
.. data:: numShards
301
310
302
- Specifies the total number of shards queried.
311
+ :data:`numShards` is a number value that returns the total number of
312
+ shards queried.
0 commit comments