#34123: Ambiguous aliases in ordering on combined queries with select_related().
-------------------------------------+-------------------------------------
     Reporter:  Shai Berger          |                    Owner:  nobody
         Type:  Bug                  |                   Status:  new
    Component:  Database layer       |                  Version:  dev
  (models, ORM)                      |
     Severity:  Release blocker      |               Resolution:
     Keywords:  select_related       |             Triage Stage:  Accepted
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Changes (by David Sanders):

 * cc: David Sanders (added)


Comment:

 Interesting read following the thread back.

 I'm guessing reverting to using column numbers is out of the question, is
 the solution here to simply alias the columns `c1`, `c2`, `c3` … etc. You
 only need to alias the first query in the union and the others follow
 suite.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/34123#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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018419bcbde8-e154398f-2634-45e7-a179-96dc99e3c90b-000000%40eu-central-1.amazonses.com.

Reply via email to