Skip to content

Commit b920945

Browse files
tim-mccurrachfelixxm
authored andcommitted
[3.1.x] Fixed #32388 -- Clarified QuerySet.bulk_update() caveat about duplicates for multiple batches.
Backport of 241da3f from master
1 parent fa203f1 commit b920945

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

docs/ref/models/querysets.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2181,7 +2181,8 @@ them, but it has a few caveats:
21812181
``batch_size``.
21822182
* Updating fields defined on multi-table inheritance ancestors will incur an
21832183
extra query per ancestor.
2184-
* If ``objs`` contains duplicates, only the first one is updated.
2184+
* When an individual batch contains duplicates, only the first instance in that
2185+
batch will result in an update.
21852186

21862187
The ``batch_size`` parameter controls how many objects are saved in a single
21872188
query. The default is to update all objects in one batch, except for SQLite

0 commit comments

Comments
 (0)