Skip to content

Commit 7983b58

Browse files
jason-price-mongodbjason-price-mongodb
andauthored
DOCSP-33423-explain-version-field (#5350)
* DOCSP-33423-explain-version-field * DOCSP-33423-explain-version-field * DOCSP-33423-explain-version-field * DOCSP-33423-explain-version-field * DOCSP-33423-explain-version-field * DOCSP-33423-explain-version-field --------- Co-authored-by: jason-price-mongodb <[email protected]>
1 parent d7a1a87 commit 7983b58

File tree

3 files changed

+26
-32
lines changed

3 files changed

+26
-32
lines changed

source/core/aggregation-pipeline-optimization.txt

Lines changed: 23 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -443,22 +443,20 @@ The following sections describe:
443443
.. include:: /includes/fact-sbe-group-overview.rst
444444

445445
When the |sbe| is used for :pipeline:`$group`, the :ref:`explain results
446-
<explain-results>` include:
446+
<explain-results>` include ``queryPlanner.winningPlan.queryPlan.stage:
447+
"GROUP"``.
447448

448-
- ``explain.explainVersion: '2'``
449-
- ``queryPlanner.winningPlan.queryPlan.stage: "GROUP"``
449+
The location of the ``queryPlanner`` object depends on whether the
450+
pipeline contains stages after the ``$group`` stage that cannot be
451+
executed using the |sbe-short|.
450452

451-
The location of the ``queryPlanner`` object depends on whether the
452-
pipeline contains stages after the ``$group`` stage which cannot be
453-
executed using the |sbe-short|.
453+
- If ``$group`` is the last stage or all stages after ``$group`` can
454+
be executed using the |sbe-short|, the ``queryPlanner`` object is in
455+
the top-level ``explain`` output object (``explain.queryPlanner``).
454456

455-
- If ``$group`` is the last stage or all stages after ``$group`` can
456-
be executed using the |sbe-short|, the ``queryPlanner`` object is in
457-
the top-level ``explain`` output object (``explain.queryPlanner``).
458-
459-
- If the pipeline contains stages after ``$group`` which cannot be
460-
executed using the |sbe-short|, the ``queryPlanner`` object is in
461-
``explain.stages[0].$cursor.queryPlanner``.
457+
- If the pipeline contains stages after ``$group`` that cannot be
458+
executed using the |sbe-short|, the ``queryPlanner`` object is in
459+
``explain.stages[0].$cursor.queryPlanner``.
462460

463461
.. _agg-lookup-optimization-sbe:
464462

@@ -470,23 +468,21 @@ When the |sbe| is used for :pipeline:`$group`, the :ref:`explain results
470468
.. include:: /includes/fact-sbe-lookup-overview.rst
471469

472470
When the |sbe| is used for :pipeline:`$lookup`, the :ref:`explain
473-
results <explain-results>` include:
474-
475-
- ``explain.explainVersion: '2'``
476-
- ``queryPlanner.winningPlan.queryPlan.stage: "EQ_LOOKUP"``.
477-
``EQ_LOOKUP`` means "equality lookup".
471+
results <explain-results>` include
472+
``queryPlanner.winningPlan.queryPlan.stage: "EQ_LOOKUP"``. ``EQ_LOOKUP``
473+
means "equality lookup".
478474

479-
The location of the ``queryPlanner`` object depends on whether the
480-
pipeline contains stages after the ``$lookup`` stage which cannot be
481-
executed using the |sbe-short|.
475+
The location of the ``queryPlanner`` object depends on whether the
476+
pipeline contains stages after the ``$lookup`` stage that cannot be
477+
executed using the |sbe-short|.
482478

483-
- If ``$lookup`` is the last stage or all stages after ``$lookup`` can
484-
be executed using the |sbe-short|, the ``queryPlanner`` object is in
485-
the top-level ``explain`` output object (``explain.queryPlanner``).
479+
- If ``$lookup`` is the last stage or all stages after ``$lookup`` can
480+
be executed using the |sbe-short|, the ``queryPlanner`` object is in
481+
the top-level ``explain`` output object (``explain.queryPlanner``).
486482

487-
- If the pipeline contains stages after ``$lookup`` which cannot be
488-
executed using the |sbe-short|, the ``queryPlanner`` object is in
489-
``explain.stages[0].$cursor.queryPlanner``.
483+
- If the pipeline contains stages after ``$lookup`` that cannot be
484+
executed using the |sbe-short|, the ``queryPlanner`` object is in
485+
``explain.stages[0].$cursor.queryPlanner``.
490486

491487
.. _aggregation-pipeline-optimization-indexes-and-filters:
492488

source/includes/explainVersion.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,2 @@
1-
``explainVersion`` is:
2-
3-
- 1 when classic query execution is used.
4-
- 2 when slot based query execution is used.
1+
``explainVersion`` is the output format version for the plan, such as
2+
``"1"`` or ``"2"``.

source/reference/explain-results.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ documentation for that version.
125125

126126
.. data:: explain.explainVersion
127127

128-
Integer field with the explain planner version.
128+
Integer field.
129129

130130
.. include:: /includes/explainVersion.rst
131131

0 commit comments

Comments
 (0)