Skip to content

Commit 20b6f92

Browse files
committed
Fix
1 parent 084742f commit 20b6f92

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

source/write/bulk-write.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,12 @@ The following example creates an instance of ``InsertOne``:
6767

6868
To insert multiple documents, create an instance of ``InsertOne`` for each document.
6969

70+
.. note::
71+
72+
Duplicate ``_id`` values violate unique index constraints, which causes the
73+
driver to return a ``DuplicateKeyError``. To avoid this error, ensure that
74+
each document you insert has a unique ``_id`` value.
75+
7076
Update Operations
7177
~~~~~~~~~~~~~~~~~
7278

0 commit comments

Comments
 (0)