Difference between Q and filter and exclude

57 views
Skip to first unread message

Larry Martell

unread,
Dec 22, 2014, 11:51:06 AM12/22/14
to django...@googlegroups.com
Is there any difference, either functional or performance wise,
between these 2 constructs:

Q(f=1) and filter(f=1)

Or, between these 2:

(~Q(f=1)) and exclude(f=1)

Anssi Kääriäinen

unread,
Dec 23, 2014, 9:16:17 AM12/23/14
to django...@googlegroups.com
These queries should be equivalent.

- Anssi
Reply all
Reply to author
Forward
0 new messages