Skip to content

Commit d81be4f

Browse files
DOCSP-31653 Remove duplicate aggregation content (#4200) (#5356)
* DOCSP-31653 Remove duplicate aggregation content (#4200) * move pages around * remove alphabetical list of stages * remove alphabetical list of operators * change header levels * remove quick reference page * fix broken refs * add missing ref * fix build errors * fix build errors * adjust page title * update toc order * fix ref link * wording * remove superfluous ref * remove superfluous ref * consistency * remove superfluous ref * fix git conflict * edits * fix ref * reorder toc
1 parent 229d5c8 commit d81be4f

16 files changed

+81
-2003
lines changed

config/redirects

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2552,4 +2552,7 @@ raw: https://api.mongodb.com/python/current/ -> ${base}/drivers/python/
25522552
raw: https://mongodb.github.io/mongo-java-driver/ -> ${base}/drivers/java/sync/current/
25532553

25542554
# DOCSP-32407
2555-
[v4.2-*]: ${prefix}/${version}/meta/aggregation-quick-reference/ -> ${prefix}/${version}/reference/aggregation-quick-reference/
2555+
[v4.2-*]: ${prefix}/${version}/meta/aggregation-quick-reference/ -> ${base}/${version}/reference/aggregation-quick-reference/
2556+
2557+
# DOCSP-31653
2558+
[v7.0-*]: ${prefix}/${version}/reference/aggregation-quick-reference/ -> ${base}/${version}/reference/aggregation/

source/core/aggregation-pipeline.txt

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ Example output:
149149
- :doc:`/tutorial/aggregation-zip-code-data-set`
150150
- :doc:`/tutorial/update-documents-with-aggregation-pipeline`
151151

152-
.. _aggregation-pipeline-stages:
152+
.. _aggregation-pipeline-stages-details:
153153

154154
Additional Aggregation Pipeline Stage Details
155155
---------------------------------------------
@@ -198,6 +198,22 @@ aggregation expressions in JavaScript.
198198

199199
For all aggregation expressions, see :ref:`aggregation-expressions`.
200200

201+
.. _agg-quick-ref-field-paths:
202+
203+
Field Paths
204+
~~~~~~~~~~~
205+
206+
Aggregation expressions use :term:`field path` to access fields in the
207+
input documents. To specify a field path, prefix the field name or the
208+
:ref:`dotted field name <document-dot-notation>` (if the field is in
209+
the embedded document) with a dollar sign ``$``. For example,
210+
``"$user"`` to specify the field path for the ``user`` field or
211+
``"$user.name"`` to specify the field path to ``"user.name"`` field.
212+
213+
``"$<field>"`` is equivalent to ``"$$CURRENT.<field>"`` where the
214+
:variable:`CURRENT` is a system variable that defaults to the root of
215+
the current object, unless stated otherwise in specific stages.
216+
201217
Run an Aggregation Pipeline
202218
---------------------------
203219

source/core/materialized-views.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ steps:
7070

7171
The aggregation stage transforms the data that you want to save as
7272
a view. To learn more about available aggregation stages, see
73-
:ref:`agg-pipeline-quick-ref`.
73+
:ref:`aggregation-pipeline-operator-reference`.
7474

7575
For this example, add a new field with the :pipeline:`$set` stage:
7676

source/includes/extracts-agg-stages.yaml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -310,14 +310,15 @@ content: |
310310
- Returns information on active and/or dormant operations for
311311
the MongoDB deployment.
312312
313+
* - :pipeline:`$documents`
314+
315+
- Returns literal documents from input values.
316+
313317
* - :pipeline:`$listLocalSessions`
314318
315319
- Lists all active sessions recently in use on the currently
316320
connected :binary:`~bin.mongos` or :binary:`~bin.mongod`
317321
instance. These sessions may have not yet propagated to the
318322
``system.sessions`` collection.
319-
320-
* - :pipeline:`$documents`
321323
322-
- Returns literal documents from input values.
323324
...

source/includes/fact-use-aggregation-not-map-reduce.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ deprecated:
55
:ref:`aggregation pipeline <aggregation-pipeline>`. Aggregation
66
pipelines provide better performance and usability than map-reduce.
77

8-
- You can rewrite map-reduce operations using :ref:`aggregation
9-
pipeline stages <agg-pipeline-quick-ref>`, such as
8+
- You can rewrite map-reduce operations using :ref:`aggregation pipeline
9+
stages <aggregation-pipeline-operator-reference>`, such as
1010
:pipeline:`$group`, :pipeline:`$merge`, and others.
1111

1212
- For map-reduce operations that require custom functionality, you can

0 commit comments

Comments
 (0)