#9519: Add QuerySet.bulk_delete() that issues only a single SQL query
-------------------------------------+-------------------------------------
     Reporter:  Tarken               |                    Owner:  nobody
         Type:  New feature          |                   Status:  new
    Component:  Database layer       |                  Version:  master
  (models, ORM)                      |               Resolution:
     Severity:  Normal               |             Triage Stage:  Accepted
     Keywords:  database, queryset,  |      Needs documentation:  0
  delete                             |  Patch needs improvement:  0
    Has patch:  0                    |                    UI/UX:  0
  Needs tests:  0                    |
Easy pickings:  0                    |
-------------------------------------+-------------------------------------

Comment (by carljm):

 If I'm not mistaken, the need for cascade is entirely determined by the
 model schema; in other words, for a given call to `bulk_delete`, the need
 for cascade won't change at runtime. In other words, you're not going to
 have code calling `bulk_delete` that usually works but occasionally fails.
 So it seems fine to me to omit (3) and just raise an error if
 `bulk_delete` is used on a model requiring cascade. Implementing (3)
 sounds to me like a lot of additional deletion code and bug surface area,
 for little benefit.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/9519#comment:22>
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 post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to