#30771: Filtering on query result overrides GROUP BY of internal query
-------------------------------------+-------------------------------------
Reporter: Aur Saraf | Owner: James
| Timmins
Type: Bug | Status: closed
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution: fixed
Keywords: annotate, | Triage Stage: Accepted
annotation, filter, groupby, |
aggregate, aggregation |
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Mariusz Felisiak <felisiak.mariusz@…>):
* status: assigned => closed
* resolution: => fixed
Comment:
In [changeset:"3697ddbf7526e85483067db5a2fde93f661da360" 3697ddb]:
{{{
#!CommitTicketReference repository=""
revision="3697ddbf7526e85483067db5a2fde93f661da360"
[3.0.x] Fixed #30771 -- Fixed exact lookup against queries with selected
columns.
Use pre-existing select fields (and thereby GROUP BY fields) from
subquery if they were specified, instead of always defaulting to pk.
Thanks Aur Saraf for the report and Simon Charette for guidance.
Backport of 0719edcd5fed56157ffb3323a8f634aa5e8f9a80 from master
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/30771#comment:10>
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/068.19cdeb22fb9152976f48e4ec123eefe0%40djangoproject.com.