Skip to content

Commit 4a6019b

Browse files
committed
Fix
1 parent 4a715b6 commit 4a6019b

File tree

1 file changed

+8
-9
lines changed

1 file changed

+8
-9
lines changed

source/fundamentals/crud/read-operations/project.txt

+8-9
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,9 @@ which fields MongoDB returns from a query.
2727
Sample Data
2828
~~~~~~~~~~~
2929

30-
The examples in this guide use the ``restaurants`` collection in the ``sample_restaurants``
31-
database from the :atlas:`Atlas sample datasets </sample-data>`. To learn how to create a
32-
free MongoDB Atlas cluster and load the sample datasets, see the
33-
:atlas:`Get Started with Atlas </getting-started>` guide.
30+
The examples in this guide use the ``sample_restaurants.restaurants`` collection
31+
from the :atlas:`Atlas sample datasets </sample-data>`. To learn how to create a
32+
free MongoDB Atlas cluster and load the sample datasets, see the :ref:`<csharp-quickstart>`.
3433

3534
The examples on this page use the following ``Restaurant`` and ``Address`` classes to model
3635
the documents in the collection:
@@ -57,15 +56,15 @@ To remove the ``_id`` field from the returned document, you must
5756
Specify Fields to Include
5857
~~~~~~~~~~~~~~~~~~~~~~~~~
5958

60-
To specify the fields to include from the result, chain the ``Projection()`` method
61-
to the ``Find()`` method. When calling the ``Projection()`` method, you must pass in the
59+
To specify the fields to include from the result, chain the ``Project()`` method
60+
to the ``Find()`` method. When calling the ``Project()`` method, you must pass in the
6261
projection definition as a parameter. You can construct a projection definition by using
6362
the ``Builders<T>.Projection.Include()`` method and passing in the field name to include
6463
as a parameter. This method can be chained to include multiple fields in the projection.
6564

6665
The following example uses the ``Find()`` method to find all restaurants in which the ``name``
67-
field value is ``"Emerald Pub"``. Then, the code calls the ``projection()`` and ``exclude()``
68-
methods to instruct the find operation to omit the ``name`` and ``address`` fields
66+
field value is ``"Emerald Pub"``. Then, the code calls the ``Project()``
67+
method to instruct the find operation to include the ``name`` and ``address`` fields
6968
in the result:
7069

7170
.. io-code-block::
@@ -112,7 +111,7 @@ excludes the ``_id`` field from the projection:
112111
Specify Fields to Exclude
113112
~~~~~~~~~~~~~~~~~~~~~~~~~
114113

115-
To specify the fields to include from the result, chain the ``Projection()`` method
114+
To specify the fields to include from the result, chain the ``Project()`` method
116115
to the ``Find()`` method. You can exclude fields in your projection by using
117116
the ``Builders<T>.Projection.Exclude()`` method and passing in the field name to exclude
118117
as a parameter. This method can be chained to exclude multiple fields in the projection.

0 commit comments

Comments
 (0)