#24835: exists() incorrect after annotation with Count()
-------------------------------------+-------------------------------------
Reporter: pteromys | Owner: pwmarcz
Type: Bug | Status: closed
Component: Database layer | Version: 1.8
(models, ORM) |
Severity: Release blocker | Resolution: fixed
Keywords: | Triage Stage: Ready for
| checkin
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Comment (by Tim Graham <timograham@…>):
In [changeset:"2aa2b9f291e43bffc07c535dc5906094e6df0bb7" 2aa2b9f]:
{{{
#!CommitTicketReference repository=""
revision="2aa2b9f291e43bffc07c535dc5906094e6df0bb7"
[1.8.x] Fixed #24835 -- Fixed QuerySet.exists() after an annotation with
Count()
QuerySet.exists() incorrectly handled query.group_by = True
case (grouping by all select fields), causing GROUP BY
expressions to be wiped along with select fields.
Backport of 801a84ae329a24d9adf01b700429fe8f1285b2b8 from master
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/24835#comment:8>
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 post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/066.2bde3a876645e0189b2de80ac4291f15%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.