#25811: Error querying models in different databases in one queryset
-------------------------------------+-------------------------------------
     Reporter:  ebar0n               |                    Owner:  nobody
         Type:                       |                   Status:  new
  Cleanup/optimization               |
    Component:  Database layer       |                  Version:  master
  (models, ORM)                      |
     Severity:  Normal               |               Resolution:
     Keywords:  database             |             Triage Stage:  Accepted
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------

Comment (by ebar0n):

 It is effectively efficiently perform the subquery, but I think Django
 must be able to identify the model referenced in the subquery belongs to a
 different base data to the initial consultation; Only then the subquery
 should be evaluated before generating the entire query, and generate the
 subquery and avoid error.

 Rest when they belong to the same database operation should be such as
 this, because it is more optimal.

 That would be the need to use the same functional code with multiple
 database support.

 Then you advise me? I'm anxious to try to fix it.

 Excuse my bad English is not my native language.

--
Ticket URL: <https://code.djangoproject.com/ticket/25811#comment:9>
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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/064.f3f12f10417d9d4b38e956d6cf2e667b%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to