Code

Ticket #13099: ticket_13099_replace_example.diff

File ticket_13099_replace_example.diff, 829 bytes (added by istruble, 4 years ago)
Line 
1Index: docs/ref/models/querysets.txt
2===================================================================
3--- docs/ref/models/querysets.txt       (revision 12773)
4+++ docs/ref/models/querysets.txt       (working copy)
5@@ -165,19 +165,8 @@
6     SELECT ...
7     WHERE NOT (pub_date > '2005-1-3' AND headline = 'Hello')
8 
9-This example excludes all entries whose ``pub_date`` is later than 2005-1-3
10-OR whose headline is "Hello"::
11+See :ref:`complex queries <complex-lookups-with-q>` for example lookups with OR.
12 
13-    Entry.objects.exclude(pub_date__gt=datetime.date(2005, 1, 3)).exclude(headline='Hello')
14-
15-In SQL terms, that evaluates to::
16-
17-    SELECT ...
18-    WHERE NOT pub_date > '2005-1-3'
19-    OR NOT headline = 'Hello'
20-
21-Note the second example is more restrictive.
22-
23 ``annotate(*args, **kwargs)``
24 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
25