#31566: Subquery in annotation is included by its alias and is not present in
the
SELECT
-------------------------------------+-------------------------------------
Reporter: Gagaro | Owner: Simon
| Charette
Type: Bug | Status: closed
Component: Database layer | Version: 3.0
(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 Mariusz Felisiak <felisiak.mariusz@…>):
In [changeset:"8cb87a3f7c413b9943a5a73e156716067267b182" 8cb87a3f]:
{{{
#!CommitTicketReference repository=""
revision="8cb87a3f7c413b9943a5a73e156716067267b182"
[3.1.x] Fixed #31566 -- Fixed aliases crash when chaining
values()/values_list() after annotate() with aggregations and subqueries.
Subquery annotation references must be resolved if they are excluded
from the GROUP BY clause by a following .values() call.
Regression in fb3f034f1c63160c0ff13c609acd01c18be12f80.
Thanks Makina Corpus for the report.
Backport of 42c08ee46539ef44f8658ebb1cbefb408e0d03fe from master
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/31566#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 [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/064.5d2a007526915e624b553fcadc94bd2b%40djangoproject.com.