diff --git a/source/reference/explain.txt b/source/reference/explain.txt index 817724a73a0..8e2017e925e 100644 --- a/source/reference/explain.txt +++ b/source/reference/explain.txt @@ -129,7 +129,8 @@ Core Explain Output .. data:: cursor - Specifies the type of cursor used in the query operation: + :data:`cursor` is a string value that returns the type of cursor + used in the query operation: - ``BasicCursor`` indicates use of full collection scan. @@ -142,27 +143,28 @@ Core Explain Output .. data:: isMultiKey - A boolean, that specifies if the index used in this query is a - :ref:`multikey index ` on a field that holds - an array. + :data:`isMultiKey` is a boolean value that returns ``true`` if the + index used in this query is a :ref:`multikey index + ` on a field that holds an array. .. data:: n - Specifies the number of documents that match the query selection - criteria. + :data:`n` is a number value that returns the number of documents + that match the query selection criteria. .. data:: nscannedObjects - Specifies the total number of documents scanned during the query. - The :data:`nscannedObjects` may be lower than :data:`nscanned`, such - as if the index is a covered index. + :data:`nscannedObjects` is a number value that returns the total + number of documents scanned during the query. The + :data:`nscannedObjects` may be lower than :data:`nscanned`, such as + if the index is a covered index. .. data:: nscanned - Specifies the total number of documents or index entries scanned - during the database operation. You want :data:`n` and - :data:`nscanned` to be close in value as possible. The - :data:`nscanned` value may be higher than the + :data:`nscanned` is a number value that returns the total number of + documents or index entries scanned during the database operation. + You want :data:`n` and :data:`nscanned` to be close in value as + possible. The :data:`nscanned` value may be higher than the :data:`nscannedObjects` value, such as if the index is a covered index. @@ -170,25 +172,27 @@ Core Explain Output .. versionadded:: 2.2 - Specifies the total number of documents scanned for all query plans - during the database operation. + :data:`nscannedObjectsAllPlans` is a number value that returns the + total number of documents scanned for all query plans during the + database operation. .. data:: nscannedAllPlans .. versionadded:: 2.2 - Specifies the total number of documents or index entries scanned for - all query plans during the database operation. + :data:`nscannedAllPlans` is a number value that returns the total + number of documents or index entries scanned for all query plans + during the database operation. .. data:: scanAndOrder .. versionadded:: 2.2 :data:`scanAndOrder` is a boolean value that returns ``true`` when - the query cannot use the index for returning sorted results. + the query **cannot** use the index for returning sorted results. - When ``false`` MongoDB must sort documents retrieving the documents - using either an index cursor or by cursor that scans the entire + When ``true``, MongoDB must sort the documents after it retrieves + them from either an index cursor or a cursor that scans the entire collection. .. data:: indexOnly @@ -200,24 +204,25 @@ Core Explain Output .. data:: nYields - Specifies the number of times this query yielded the read lock to - allow waiting writes execute. + :data:`nYields` is a number value that returns the number of times + this query yielded the read lock to allow waiting writes execute. .. data:: nChunkSkips - Specifies the number of documents skipped because of active chunk - migrations in a sharded system. Typically this will be zero. A - number greater than zero is ok, but indicates a little bit of - inefficiency. + :data:`nChunkSkips` is a number value that returns the number of + documents skipped because of active chunk migrations in a sharded + system. Typically this will be zero. A number greater than zero is + ok, but indicates a little bit of inefficiency. .. data:: millis - Specifies the number of milliseconds to complete the query. + :data:`millis` is a number value that returns the time in + milliseconds to complete the query. .. data:: indexBounds - Specifies the lower and upper index key bounds. This field - resembles one of the following: + :data:`indexBounds` is a document that contains the lower and upper + index key bounds. This field resembles one of the following: .. code-block:: javascript @@ -234,24 +239,25 @@ Core Explain Output .. data:: allPlans - Specifies the list of plans the query optimizer runs in order to - select the index for the query. Displays only when the ```` - parameter to :method:`explain() ` is - ``true`` or ``1``. + :data:`allPlans` is an array value that returns the list of plans + the query optimizer runs in order to select the index for the query. + Displays only when the ```` parameter to :method:`explain() + ` is ``true`` or ``1``. .. data:: oldPlan .. versionadded:: 2.2 - Specifies the previous plan selected by the query optimizer for the - query. Displays only when the ```` parameter to - :method:`explain() ` is ``true`` or ``1``. + :data:`oldPlan` is a document value that returns the previous plan + selected by the query optimizer for the query. Displays only when + the ```` parameter to :method:`explain() + ` is ``true`` or ``1``. .. data:: server .. versionadded:: 2.2 - Specifies the MongoDB server. + :data:`server` is a string value that returns the MongoDB server. .. _explain-output-field-or-clauses: @@ -260,10 +266,10 @@ Core Explain Output .. data:: clauses - Contains the :ref:`explain-output-fields-core` information for each - clause of the :operator:`$or` expression. :data:`classes` is only - included when the clauses in the :operator:`$or` expression use - indexes. + :data:`clauses` is an array value that returns the + :ref:`explain-output-fields-core` information for each clause of the + :operator:`$or` expression. :data:`classes` is only included when + the clauses in the :operator:`$or` expression use indexes. .. _explain-output-fields-sharded-collection: @@ -272,7 +278,8 @@ Sharded Collections Output .. data:: clusteredType - Describes the access pattern for shards. The value is: + :data:`clusteredType` is a string value that returns the access + pattern for shards. The value is: - ``ParallelSort``, if the :program:`mongos` queries shards in parallel. @@ -280,23 +287,26 @@ Sharded Collections Output .. data:: shards - Specifies the shards accessed during the query and individual - :ref:`explain-output-fields-core` for each shard. + :data:`shards` is a document value that contains the shards accessed + during the query and individual :ref:`explain-output-fields-core` + for each shard. .. data:: millisShardTotal - Specifies the total time in milliseconds for the query to run on the - shards. + :data:`millisShardTotal` is a number value that returns the total + time in milliseconds for the query to run on the shards. .. data:: millisShardAvg - Specifies the average time in millisecond for the query to run on - each shard. + :data:`millisShardAvt` is a number value that returns the average + time in millisecond for the query to run on each shard. .. data:: numQueries - Specifies the total number of queries executed. + :data:`numQueries` is a number value that returns the total number + of queries executed. .. data:: numShards - Specifies the total number of shards queried. + :data:`numShards` is a number value that returns the total number of + shards queried. diff --git a/source/reference/method/cursor.explain.txt b/source/reference/method/cursor.explain.txt index 45366885b66..3512baffb45 100644 --- a/source/reference/method/cursor.explain.txt +++ b/source/reference/method/cursor.explain.txt @@ -79,10 +79,10 @@ cursor.explain() - :operator:`$explain` - - :wiki:`Optimization` wiki page for information regarding - optimization strategies. + - :doc:`/applications/optimization` page for information + regarding optimization strategies. - - :wiki:`Database Profiler` wiki page for information regarding - optimization strategies. + - :doc:`/tutorial/manage-the-database-profiler` tutorial for + information regarding the database profile. - :doc:`Current Operation Reporting ` diff --git a/source/reference/operator/explain.txt b/source/reference/operator/explain.txt index f664f1f5eee..94add622721 100644 --- a/source/reference/operator/explain.txt +++ b/source/reference/operator/explain.txt @@ -73,10 +73,10 @@ $explain - :method:`cursor.explain()` - - :wiki:`Optimization` wiki page for information regarding - optimization strategies. + - :doc:`/applications/optimization` page for information + regarding optimization strategies. - - :wiki:`Database Profiler` wiki page for information regarding - optimization strategies. + - :doc:`/tutorial/manage-the-database-profiler` tutorial for + information regarding the database profile. - :doc:`Current Operation Reporting `