Skip to content

Commit 229d5c8

Browse files
jason-price-mongodbjason-price-mongodb
andauthored
DOCSP-33423-explain-version-field (#5350) (#5354)
* 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 64af623 commit 229d5c8

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
@@ -435,22 +435,20 @@ The following sections describe:
435435
.. include:: /includes/fact-sbe-group-overview.rst
436436

437437
When the |sbe| is used for :pipeline:`$group`, the :ref:`explain results
438-
<explain-results>` include:
438+
<explain-results>` include ``queryPlanner.winningPlan.queryPlan.stage:
439+
"GROUP"``.
439440

440-
- ``explain.explainVersion: '2'``
441-
- ``queryPlanner.winningPlan.queryPlan.stage: "GROUP"``
441+
The location of the ``queryPlanner`` object depends on whether the
442+
pipeline contains stages after the ``$group`` stage that cannot be
443+
executed using the |sbe-short|.
442444

443-
The location of the ``queryPlanner`` object depends on whether the
444-
pipeline contains stages after the ``$group`` stage which cannot be
445-
executed using the |sbe-short|.
445+
- If ``$group`` is the last stage or all stages after ``$group`` can
446+
be executed using the |sbe-short|, the ``queryPlanner`` object is in
447+
the top-level ``explain`` output object (``explain.queryPlanner``).
446448

447-
- If ``$group`` is the last stage or all stages after ``$group`` can
448-
be executed using the |sbe-short|, the ``queryPlanner`` object is in
449-
the top-level ``explain`` output object (``explain.queryPlanner``).
450-
451-
- If the pipeline contains stages after ``$group`` which cannot be
452-
executed using the |sbe-short|, the ``queryPlanner`` object is in
453-
``explain.stages[0].$cursor.queryPlanner``.
449+
- If the pipeline contains stages after ``$group`` that cannot be
450+
executed using the |sbe-short|, the ``queryPlanner`` object is in
451+
``explain.stages[0].$cursor.queryPlanner``.
454452

455453
.. _agg-lookup-optimization-sbe:
456454

@@ -462,23 +460,21 @@ When the |sbe| is used for :pipeline:`$group`, the :ref:`explain results
462460
.. include:: /includes/fact-sbe-lookup-overview.rst
463461

464462
When the |sbe| is used for :pipeline:`$lookup`, the :ref:`explain
465-
results <explain-results>` include:
466-
467-
- ``explain.explainVersion: '2'``
468-
- ``queryPlanner.winningPlan.queryPlan.stage: "EQ_LOOKUP"``.
469-
``EQ_LOOKUP`` means "equality lookup".
463+
results <explain-results>` include
464+
``queryPlanner.winningPlan.queryPlan.stage: "EQ_LOOKUP"``. ``EQ_LOOKUP``
465+
means "equality lookup".
470466

471-
The location of the ``queryPlanner`` object depends on whether the
472-
pipeline contains stages after the ``$lookup`` stage which cannot be
473-
executed using the |sbe-short|.
467+
The location of the ``queryPlanner`` object depends on whether the
468+
pipeline contains stages after the ``$lookup`` stage that cannot be
469+
executed using the |sbe-short|.
474470

475-
- If ``$lookup`` is the last stage or all stages after ``$lookup`` can
476-
be executed using the |sbe-short|, the ``queryPlanner`` object is in
477-
the top-level ``explain`` output object (``explain.queryPlanner``).
471+
- If ``$lookup`` is the last stage or all stages after ``$lookup`` can
472+
be executed using the |sbe-short|, the ``queryPlanner`` object is in
473+
the top-level ``explain`` output object (``explain.queryPlanner``).
478474

479-
- If the pipeline contains stages after ``$lookup`` which cannot be
480-
executed using the |sbe-short|, the ``queryPlanner`` object is in
481-
``explain.stages[0].$cursor.queryPlanner``.
475+
- If the pipeline contains stages after ``$lookup`` that cannot be
476+
executed using the |sbe-short|, the ``queryPlanner`` object is in
477+
``explain.stages[0].$cursor.queryPlanner``.
482478

483479
.. _aggregation-pipeline-optimization-indexes-and-filters:
484480

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)