Skip to content

Commit ac944c1

Browse files
jason-price-mongodbjason-price-mongodb
andauthored
DOCSP-33423-explain-version-field (#5350) (#5355)
* 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 7b390e2 commit ac944c1

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

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

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

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

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

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

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

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

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

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

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

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

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 slot based query execution is not 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
@@ -122,7 +122,7 @@ documentation for that version.
122122

123123
.. data:: explain.explainVersion
124124

125-
Integer field with the explain planner version.
125+
Integer field.
126126

127127
.. include:: /includes/explainVersion.rst
128128

0 commit comments

Comments
 (0)