#34176: Annotation's original field-name can clash with result field name over
aggregation
-------------------------------------+-------------------------------------
     Reporter:  Shai Berger          |                    Owner:  Simon
                                     |  Charette
         Type:  Bug                  |                   Status:  assigned
    Component:  Database layer       |                  Version:  dev
  (models, ORM)                      |
     Severity:  Release blocker      |               Resolution:
     Keywords:                       |             Triage Stage:  Accepted
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Changes (by Simon Charette):

 * owner:  nobody => Simon Charette
 * status:  new => assigned


Comment:

 Thanks for the report Shai.

 I stumbled upon something similar in #34123 when trying to have
 `get_select` use the `values` aliases instead of `colN` ones for aesthetic
 reasons.

 Changes are required in `SQLCompiler.get_select` that are similar to
 
[https://github.com/django/django/blob/7d5329852f19c6ae78c6f6f3d3e41835377bf295/django/db/models/sql/query.py#L2221-L2245
 the ones] in `sql.Query.set_group_by(allow_aliases=True)`.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/34176#comment:2>
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/010701849f90b06b-9376604b-f00c-4040-b55a-0acff48e3918-000000%40eu-central-1.amazonses.com.

Reply via email to