[Django] #32333: _raw_delete won't work as expected on union'ed QuerySets

9 views
Skip to first unread message

Django

unread,
Jan 8, 2021, 12:32:33 PM1/8/21
to django-...@googlegroups.com
#32333: _raw_delete won't work as expected on union'ed QuerySets
-------------------------------------+-------------------------------------
Reporter: Faham | Owner: nobody
Negini |
Type: | Status: new
Uncategorized |
Component: Database | Version: 2.2
layer (models, ORM) |
Severity: Normal | Keywords: _raw_delete, union
Triage Stage: | Has patch: 0
Unreviewed |
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-------------------------------------+-------------------------------------
I have multiple QuerySets combined into one through `union`, calling
_raw_delete on this combined QuerySet won't delete the union result of all
sub QuerySets.

`Q1.union(Q2)._raw_delete()` removes only results of Q1 while it's
expected to remove results of `Q1.union(Q2)`

--
Ticket URL: <https://code.djangoproject.com/ticket/32333>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Jan 8, 2021, 1:54:36 PM1/8/21
to django-...@googlegroups.com
#32333: _raw_delete won't work as expected on union'ed QuerySets
-------------------------------------+-------------------------------------
Reporter: Faham Negini | Owner: nobody
Type: Uncategorized | Status: closed
Component: Database layer | Version: 2.2
(models, ORM) |
Severity: Normal | Resolution: invalid

Keywords: _raw_delete, union | Triage Stage:
| Unreviewed
Has patch: 0 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Mariusz Felisiak):

* status: new => closed
* resolution: => invalid


Comment:

`_raw_delete()` is an internal API, even calling `QuerySet.delete()` on
combined queries is not supported.

Closing per TicketClosingReasons/UseSupportChannels.

--
Ticket URL: <https://code.djangoproject.com/ticket/32333#comment:1>

Reply all
Reply to author
Forward
0 new messages