Skip to content

Commit 4f7bbe9

Browse files
committed
fixes
1 parent 33cae16 commit 4f7bbe9

File tree

9 files changed

+36
-29
lines changed

9 files changed

+36
-29
lines changed

source/fundamentals/crud/write-operations/bulk-write.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -559,7 +559,8 @@ Additional Information
559559

560560
To learn how to perform individual write operations, see the following guides:
561561

562-
- :ref:`csharp-change-guide`
562+
- :ref:`csharp-update-one`
563+
- :ref:`csharp-update-many`
563564
- :ref:`csharp-insert-guide`
564565
- :ref:`csharp-delete-guide`
565566

source/fundamentals/crud/write-operations/replace.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ method. These methods accept the following parameters:
7777
query filters, see the
7878
:manual:`{+mdb-server+} manual </core/document/#query-filter-documents>`.
7979

80-
**Data Type:** `FilterDefinition<TDocument> <{+new-api-root+>/MongoDB.Driver/MongoDB.Driver.FilterDefinition-1.html>`__
80+
**Data Type:** `FilterDefinition<TDocument> <{+new-api-root+}/MongoDB.Driver/MongoDB.Driver.FilterDefinition-1.html>`__
8181

8282
* - ``replacement``
8383
- A *replacement* document, which specifies the fields and values to insert in the new
@@ -90,7 +90,7 @@ method. These methods accept the following parameters:
9090
- *Optional.* An instance of the ``ReplaceOptions`` class that specifies the
9191
configuration for the replace operation. The default value is ``null``.
9292

93-
**Data Type:** `ReplaceOptions <{+new-api-root+>/MongoDB.Driver/MongoDB.Driver.ReplaceOptions.html>`__
93+
**Data Type:** `ReplaceOptions <{+new-api-root+}/MongoDB.Driver/MongoDB.Driver.ReplaceOptions.html>`__
9494

9595
* - ``cancellationToken``
9696
- *Optional.* A token that you can use to cancel the operation.
@@ -265,7 +265,7 @@ The ``ReplaceOneResult`` class contains the following properties:
265265
- The ID of the document that was upserted in the database, if the driver
266266
performed an upsert.
267267

268-
**Data Type:** `BsonValue <{+new-api-root+}/MongoDB.Bson/MongoDB.Bson.BsonValue.html>`__
268+
**Data Type:** `BsonValue <{+new-api-root+}/MongoDB.Bson/MongoDB.Bson.BsonValue.html>`__
269269

270270
API Documentation
271271
~~~~~~~~~~~~~~~~~

source/fundamentals/crud/write-operations/update-many.txt

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
.. _csharp-change-guide:
21
.. _csharp-update-many:
32

43
===========
@@ -38,10 +37,14 @@ Update Many
3837

3938
documents
4039

41-
.. replacement:: tab-id
40+
.. replacement:: fields-link
41+
42+
:ref:`csharp-update-many-fields`
43+
44+
.. replacement:: arrays-link
45+
46+
:ref:`csharp-update-many-arrays`
4247

43-
update-many
44-
4548
.. replacement:: single-or-multiple
4649

4750
multiple documents

source/fundamentals/crud/write-operations/update-one.txt

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
.. _csharp-change-guide:
21
.. _csharp-update-one:
32

43
==========
@@ -38,10 +37,14 @@ Update One
3837

3938
document
4039

41-
.. replacement:: tab-id
40+
.. replacement:: fields-link
4241

43-
update-one
44-
42+
:ref:`csharp-update-one-fields`
43+
44+
.. replacement:: arrays-link
45+
46+
:ref:`csharp-update-one-arrays`
47+
4548
.. replacement:: single-or-multiple
4649

4750
a single document

source/includes/code-examples/replace-one/ReplaceOne.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ public static void Main(string[] args)
4747

4848
private static ReplaceOneResult ReplaceOneRestaurant()
4949
{
50-
// start-replace-one-sync
50+
// start-replace-one
5151
// Creates a filter for all restaurant documents that have a "cuisine" value of "Pizza"
5252
var filter = Builders<Restaurant>.Filter
5353
.Eq(r => r.Cuisine, "Pizza");
@@ -67,7 +67,7 @@ private static ReplaceOneResult ReplaceOneRestaurant()
6767

6868
// Replaces the existing restaurant document with the new document
6969
return _restaurantsCollection.ReplaceOne(filter, newPizzaRestaurant);
70-
// end-replace-one-sync
70+
// end-replace-one
7171
}
7272

7373
private static ReplaceOneResult ReplaceOneRestaurantWithOptions()

source/includes/page-templates/update/update.rst

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ values in MongoDB documents.
77
The {+driver-short+} provides the following methods to update values:
88

99
- |sync-method|: Updates one or more fields in |single-or-multiple|.
10-
- |async-method|: The asynchronous version of |sync-method|()``.
10+
- |async-method|: The asynchronous version of |sync-method|.
1111

1212
The following sections describe these methods in more detail.
1313

@@ -35,13 +35,12 @@ The |sync-method| and |async-method| methods accept the following parameters:
3535
to update.
3636
To learn how to create a query filter, see :ref:`csharp-specify-query`.
3737

38-
**Data Type:** `FilterDefinition <{+new-api-root+}/MongoDB.Driver/MongoDB.Driver.FilterDefinition-1.html>`
38+
**Data Type:** `FilterDefinition <{+new-api-root+}/MongoDB.Driver/MongoDB.Driver.FilterDefinition-1.html>`__
3939

4040
* - ``update``
4141
- An instance of the ``UpdateDefinition`` class. This object specifies the kind of update
4242
operation, the fields to update, and the new value for each field. To learn how to
43-
create an ``UpdateDefinition`` object,
44-
see :ref:`csharp-|tab-id|-fields` and :ref:`csharp-|tab-id|-arrays`.
43+
create an ``UpdateDefinition`` object, see |fields-link| and |arrays-link|.
4544

4645
**Data Type:** `UpdateDefinition<TDocument> <{+new-api-root+}/MongoDB.Driver/MongoDB.Driver.UpdateDefinition-1.html>`__
4746

source/quick-reference.txt

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -180,8 +180,8 @@ their related reference and API documentation.
180180
* - | **Update a Document**
181181
|
182182
| `API Documentation <{+new-api-root+}/MongoDB.Driver/MongoDB.Driver.IMongoCollection-1.UpdateOne.html>`__
183-
| :ref:`Usage Example <csharp-update-one>`
184-
| :ref:`Fundamentals <csharp-update-operation>`
183+
| :ref:`Usage Example <csharp-examples-update-one>`
184+
| :ref:`Fundamentals <csharp-update-one>`
185185

186186
- .. code-block:: csharp
187187
:copyable: true
@@ -197,8 +197,8 @@ their related reference and API documentation.
197197
* - | **Update a Document (Async)**
198198
|
199199
| `API Documentation <{+new-api-root+}/MongoDB.Driver/MongoDB.Driver.IMongoCollection-1.UpdateOneAsync.html>`__
200-
| :ref:`Usage Example <csharp-update-one>`
201-
| :ref:`Fundamentals <csharp-update-operation>`
200+
| :ref:`Usage Example <csharp-examples-update-one>`
201+
| :ref:`Fundamentals <csharp-update-one>`
202202

203203
- .. code-block:: csharp
204204
:copyable: true
@@ -214,8 +214,8 @@ their related reference and API documentation.
214214
* - | **Update Multiple Documents**
215215
|
216216
| `API Documentation <{+new-api-root+}/MongoDB.Driver/MongoDB.Driver.IMongoCollection-1.UpdateMany.html>`__
217-
| :ref:`Usage Example <csharp-update-many>`
218-
| :ref:`Fundamentals <csharp-update-operation>`
217+
| :ref:`Usage Example <csharp-examples-update-many>`
218+
| :ref:`Fundamentals <csharp-update-many>`
219219

220220
- .. code-block:: csharp
221221
:copyable: true
@@ -231,8 +231,8 @@ their related reference and API documentation.
231231
* - | **Update Multiple Documents (Async)**
232232
|
233233
| `API Documentation <{+new-api-root+}/MongoDB.Driver/MongoDB.Driver.IMongoCollection-1.UpdateManyAsync.html>`__
234-
| :ref:`Usage Example <csharp-update-many>`
235-
| :ref:`Fundamentals <csharp-update-operation>`
234+
| :ref:`Usage Example <csharp-examples-update-many>`
235+
| :ref:`Fundamentals <csharp-update-many>`
236236

237237
- .. code-block:: csharp
238238
:copyable: true
@@ -248,7 +248,8 @@ their related reference and API documentation.
248248
* - | **Update an Array in a Document**
249249
|
250250
| `API Documentation <{+new-api-root+}/MongoDB.Driver/MongoDB.Driver.IMongoCollection-1.UpdateOne.html>`__
251-
| :ref:`Fundamentals <csharp-update-operation>`
251+
| :ref:`Fundamentals (Update One) <csharp-update-one-arrays>`
252+
| :ref:`Fundamentals (Update Many) <csharp-update-many-arrays>`
252253

253254
- .. code-block:: csharp
254255
:copyable: true

source/usage-examples/updateMany.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ Running either of the preceding full examples prints the following results:
7373
More Information
7474
----------------
7575

76-
To learn more about updating documents, see the :ref:`csharp-change-guide` guide.
76+
To learn more about updating documents, see the :ref:`csharp-update-many` guide.
7777

7878
To learn more about using builders, see :ref:`csharp-builders`.
7979

source/usage-examples/updateOne.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ writes the following to the console:
8686
More Information
8787
----------------
8888

89-
To learn more about updating documents, see the :ref:`csharp-change-guide` guide.
89+
To learn more about updating documents, see the :ref:`csharp-update-one` guide.
9090

9191
To learn more about using builders, see :ref:`csharp-builders`.
9292

0 commit comments

Comments
 (0)