Skip to content

Commit dc9560b

Browse files
ajhuh-mdbandf-mongodb
authored andcommitted
DOCSP-15266 indicate results of other projector value inputs
1 parent 2e1b2be commit dc9560b

File tree

2 files changed

+10
-5
lines changed

2 files changed

+10
-5
lines changed

source/includes/extracts-projection.yaml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,8 @@ content: |
142142
143143
* - ``<field>: <1 or true>``
144144
145-
- Specifies the inclusion of a field.
145+
- Specifies the inclusion of a field. Non-zero integers are also
146+
treated as ``true``.
146147
147148
* - ``<field>: <0 or false>``
148149
@@ -154,7 +155,8 @@ content: |
154155
you can specify the projection to return the **first** element
155156
that match the query condition on the array field; e.g.
156157
``"arrayField.$" : 1``. (Not available for :doc:`views
157-
</core/views>`.)
158+
</core/views>`.) Non-zero integers are also treated as
159+
``true``.
158160
159161
* - ``<field>: <array projection>``
160162
@@ -217,7 +219,8 @@ content: |
217219
218220
* - ``<field>: <1 or true>``
219221
220-
- Specifies the inclusion of a field.
222+
- Specifies the inclusion of a field. Non-zero integers are also
223+
treated as ``true``.
221224
222225
* - ``<field>: <0 or false>``
223226
@@ -229,7 +232,8 @@ content: |
229232
you can specify the projection to return the **first** element
230233
that match the query condition on the array field; e.g.
231234
``"arrayField.$" : 1``. (Not available for :doc:`views
232-
</core/views>`.)
235+
</core/views>`.) Non-zero integers are also treated as
236+
``true``.
233237
234238
* - ``<field>: <array projection>``
235239

source/reference/operator/aggregation/project.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,8 @@ Definition
4141

4242
* - ``<field>: <1 or true>``
4343

44-
- Specifies the inclusion of a field.
44+
- Specifies the inclusion of a field. Non-zero integers are also
45+
treated as ``true``.
4546

4647
* - ``_id: <0 or false>``
4748
- Specifies the suppression of the ``_id`` field.

0 commit comments

Comments
 (0)