Answer the question
In order to leave comments, you need to log in
How to filter a Django queryset?
How to filter a Django queryset?
I don't know how to explain, so I'll give an example:
TestModel.objects.filter(field__in=[1,2,3]) - how to make the queriset contain all objects that have at least one of the listed? Now returns only those that have all three values at the same time
Object Q tried, but it is not known in advance how many parameters will be in []
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question