Skip to content

Commit c5dcae5

Browse files
Fix definition for bulk write update operation (#1669)
1 parent dc14887 commit c5dcae5

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

source/crud/bulk-write.md

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -518,10 +518,15 @@ If the document to be inserted does not contain an `_id` field, drivers MUST gen
518518
"multi": Optional<Boolean>,
519519
"upsert": Optional<Boolean>,
520520
"arrayFilters": Optional<Array>,
521-
"hint": Optional<Document | String>
521+
"hint": Optional<Document | String>,
522+
"collation": Optional<Document>
522523
}
523524
```
524525

526+
The `update` command document is used for update and replace operations. For update operations, the `updateMods` field
527+
corresponds to the `update` field in `UpdateOneModel` and `UpdateManyModel`. For replace operations, the `updateMods`
528+
field corresponds to the `replacement` field in `ReplaceOneModel`.
529+
525530
#### Delete
526531

527532
```javascript
@@ -866,6 +871,8 @@ batch-splitting to standardize implementations across drivers and simplify batch
866871

867872
## **Changelog**
868873

874+
- 2024-09-25: Add `collation` field to `update` document and clarify usage of `updateMods`.
875+
869876
- 2024-09-25: Update the `partialResult` population logic to account for ordered bulk writes.
870877

871878
- 2024-09-18: Relax numeric type requirements for indexes.

0 commit comments

Comments
 (0)