Re: [Django] #15787: select_related with nested fields affects query result

13 views
Skip to first unread message

Django

unread,
Aug 23, 2011, 1:26:08 AM8/23/11
to django-...@googlegroups.com
#15787: select_related with nested fields affects query result
-------------------------------------+-------------------------------------
Reporter: | Owner: nobody
kriomant@… | Status: new
Type: Bug | Component: Database layer
Milestone: | (models, ORM)
Version: 1.3 | Severity: Normal
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 mtredinnick):

* ui_ux: => 0


Comment:

The initial observation is correct: `select_related()` is only an
optimisation and should never change the results returned at the outermost
object level (it will, of course, select extra lower-level objects).

--
Ticket URL: <https://code.djangoproject.com/ticket/15787#comment:2>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Nov 12, 2011, 7:59:38 PM11/12/11
to django-...@googlegroups.com
#15787: select_related with nested fields affects query result
-------------------------------------+-------------------------------------
Reporter: kriomant@… | Owner: nobody
Type: Bug | Status: new
Component: Database layer | Version: 1.3
(models, ORM) | Resolution:
Severity: Normal | Triage Stage: Accepted
Keywords: | Needs documentation: 0
Has patch: 0 | Patch needs improvement: 0
Needs tests: 0 | UI/UX: 0
Easy pickings: 0 |
-------------------------------------+-------------------------------------
Changes (by volrath):

* cc: daniel.barreto.n@… (added)


--
Ticket URL: <https://code.djangoproject.com/ticket/15787#comment:3>

Django

unread,
Nov 23, 2011, 6:20:47 AM11/23/11
to django-...@googlegroups.com
#15787: select_related with nested fields affects query result
-------------------------------------+-------------------------------------
Reporter: kriomant@… | Owner: nobody
Type: Bug | Status: new
Component: Database layer | Version: 1.3
(models, ORM) | Resolution:
Severity: Normal | Triage Stage: Accepted
Keywords: | Needs documentation: 0
Has patch: 0 | Patch needs improvement: 0
Needs tests: 0 | UI/UX: 0
Easy pickings: 0 |
-------------------------------------+-------------------------------------
Changes (by l0ki):

* cc: l0ki (added)


--
Ticket URL: <https://code.djangoproject.com/ticket/15787#comment:4>

Django

unread,
Aug 1, 2015, 9:42:35 AM8/1/15
to django-...@googlegroups.com
#15787: select_related with nested fields affects query result
-------------------------------------+-------------------------------------
Reporter: kriomant@… | Owner: nobody
Type: Bug | Status: closed

Component: Database layer | Version: 1.3
(models, ORM) |
Severity: Normal | Resolution: fixed

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 timgraham):

* status: new => closed
* resolution: => fixed


Comment:

Fixed in a193372753ad9d1d15ad5e2d6d06bbc07ca3f433

--
Ticket URL: <https://code.djangoproject.com/ticket/15787#comment:5>

Reply all
Reply to author
Forward
0 new messages