File tree Expand file tree Collapse file tree 8 files changed +21
-107
lines changed Expand file tree Collapse file tree 8 files changed +21
-107
lines changed Original file line number Diff line number Diff line change @@ -1132,15 +1132,11 @@ Alphabetical Listing of Expression Operators
1132
1132
/reference/operator/aggregation/convert
1133
1133
/reference/operator/aggregation/cos
1134
1134
/reference/operator/aggregation/cosh
1135
- <<<<<<< HEAD
1136
- /reference/operator/aggregation/count-accum
1137
- /reference/operator/aggregation/dateAdd
1138
- /reference/operator/aggregation/dateDiff
1139
- =======
1140
1135
/reference/operator/aggregation/count-accumulator
1141
1136
/reference/operator/aggregation/covariancePop
1142
1137
/reference/operator/aggregation/covarianceSamp
1143
- >>>>>>> f7253052c... DOCSP-10258 window functions
1138
+ /reference/operator/aggregation/dateAdd
1139
+ /reference/operator/aggregation/dateDiff
1144
1140
/reference/operator/aggregation/dateFromParts
1145
1141
/reference/operator/aggregation/dateSubtract
1146
1142
/reference/operator/aggregation/dateToParts
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -19,8 +19,7 @@ Definition
19
19
20
20
Returns the number of documents.
21
21
22
- .. admonition:: Disambiguation
23
- :class: note
22
+ .. note:: Disambiguation
24
23
25
24
This page describes the ``$count`` aggregation accumulator. For the
26
25
``$count`` aggregation pipeline stage, see :pipeline:`$count
@@ -47,6 +46,16 @@ Returns the number of documents.
47
46
48
47
:group:`$count` does not accept any parameters.
49
48
49
+ Behavior
50
+ --------
51
+
52
+ :group:`$count` is functionally equivalent to using ``{ $sum : 1 }``
53
+ within the :pipeline:`$group` stage.
54
+
55
+ .. seealso::
56
+
57
+ :group:`$sum`
58
+
50
59
Examples
51
60
--------
52
61
Original file line number Diff line number Diff line change @@ -20,8 +20,7 @@ Definition
20
20
Passes a document to the next stage that contains a count of the
21
21
number of documents input to the stage.
22
22
23
- .. admonition:: Disambiguation
24
- :class: note
23
+ .. note:: Disambiguation
25
24
26
25
This page describes the ``$count`` aggregation pipeline stage.
27
26
For the ``$count`` aggregation accumulator, see :group:`$count
Original file line number Diff line number Diff line change @@ -23,8 +23,7 @@ documents. Only meaningful when documents are in a defined order.
23
23
24
24
.. include:: /includes/extracts/fact-aggregation-accumulator-first.rst
25
25
26
- .. admonition:: Disambiguation
27
- :class: note
26
+ .. note:: Disambiguation
28
27
29
28
This page describes the :group:`$first` aggregation accumulator. For
30
29
the :expression:`$first` array operator, see :expression:`$first
Original file line number Diff line number Diff line change @@ -59,9 +59,9 @@ documents forming a trapezoid using the:
59
59
Specifies the :ref:`expression <aggregation-expressions>` to
60
60
evaluate. You must provide an expression that returns a number.
61
61
62
- * - :ref:`unit <integral-outputUnit >`
62
+ * - :ref:`unit <integral-unit >`
63
63
64
- - .. _integral-outputUnit :
64
+ - .. _integral-unit :
65
65
66
66
.. include:: /includes/outputUnit-behavior.rst
67
67
Original file line number Diff line number Diff line change @@ -23,8 +23,7 @@ Only meaningful when documents are in a defined order.
23
23
24
24
.. include:: /includes/extracts/fact-aggregation-accumulator-last.rst
25
25
26
- .. admonition:: Disambiguation
27
- :class: note
26
+ .. note:: Disambiguation
28
27
29
28
This page describes the :group:`$last` aggregation accumulator. For
30
29
the :expression:`$last` array operator, see :expression:`$last (array
Original file line number Diff line number Diff line change @@ -40,8 +40,9 @@ MongoDB 5.0 introduces the following aggregation operators:
40
40
41
41
* - :group:`$count`
42
42
- :group:`$count (aggregation accumulator) <$count>`
43
- provides a count of all documents when used in a
44
- :pipeline:`$group (aggregation) <$group>` pipeline stage.
43
+ provides a count of all documents when used in the existing
44
+ pipeline :pipeline:`$group (aggregation) <$group>` stage and the
45
+ new MongoDB 5.0 :pipeline:`$setWindowFields` stage.
45
46
46
47
.. note:: Disambiguation
47
48
You can’t perform that action at this time.
0 commit comments