Object.objects.values_list("v1","v2").filter(AnotherObject.objects.values_list("v1","v2"))
Eg,
[(1,2),(5,7),(3,8),(9,3)].filter ([(1,2),(3,9)]) = [(5,7),(3,8),(9,3)]
here (9,3) == (3,9) is false. Non-commutative
For commutative comparison we have Eg,
[(1,2),(5,7),(3,8),(9,3)].filter ([(1,2),(3,9)]) = [(5,7),(3,8)]
here (9,3) == (3,9) is true.
The non-commutative case was necessary in an example I had. I hacked it
where I created lists and compared using lists. However this requires a db
evaluation.
--
Ticket URL: <https://code.djangoproject.com/ticket/25982>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
* needs_better_patch: => 0
* needs_tests: => 0
* needs_docs: => 0
Comment:
Could you refine the description with some actual models and sample code.
It's a bit unclear as is. Thanks.
--
Ticket URL: <https://code.djangoproject.com/ticket/25982#comment:1>
* status: new => closed
* resolution: => needsinfo
--
Ticket URL: <https://code.djangoproject.com/ticket/25982#comment:2>