dimanche 28 juin 2015

Check whether the query is not exist or has a specific value

For instance we have Example model and we want to do something like below:

ex = Example.objects.filter(Q(participant__tries=0) | Q(participant__tries=*THERE IS NO EXAMPLE RECORD*), courses=course)

What should we replace in between two stars?

Aucun commentaire:

Enregistrer un commentaire