#31003: Suggesting: Documentation update for bulk_create method
-------------------------------------+-------------------------------------
Reporter: Fizzizist | Owner: nobody
Type: | Status: new
Cleanup/optimization |
Component: | Version: 2.2
Documentation | Keywords: bulk_create,
Severity: Normal | database, query,
Triage Stage: | Has patch: 0
Unreviewed |
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-------------------------------------+-------------------------------------
This suggestion relates to the `bulk_create` method for creating model
objects https://docs.djangoproject.com/en/2.2/ref/models/querysets/#bulk-
create. Currently the documentation states what the method does and the
caveats associated with its use, but there is no information on what it
returns, and in what order the list is returned.
I would be willing to make this modification myself, but I actually don't
know if the order of the list is guaranteed to be the same as the order of
the input list. This would be really useful information for developers.
For example, I currently have a piece of code in my codebase that uses
`bulk_create` and then performs an additional check on the output list to
ensure that it is ordered properly. This step would be able to be removed
if I know that the `bulk_create` method outputs the list in the same order
as the input list every time. If someone who knows this information could
send it to me, I can make this change in the documentation myself,
otherwise, someone with that knowledge can make the change.
--
Ticket URL: <https://code.djangoproject.com/ticket/31003>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/052.3956ba8c2803c66600feac92f9155f8d%40djangoproject.com.