Ticket #11931: fkdocs.diff

File fkdocs.diff, 1.5 KB (added by Daniel Roseman, 15 years ago)

Documentation patch

  • docs/topics/db/queries.txt

     
    622622    >>> print [p.headline for p in queryset] # Evaluate the query set.
    623623    >>> print [p.pub_date for p in queryset] # Re-use the cache from the evaluation.
    624624
     625.. _complex_lookups_with_q:
     626
    625627Complex lookups with Q objects
    626628==============================
    627629
     
    629631you need to execute more complex queries (for example, queries with ``OR``
    630632statements), you can use ``Q`` objects.
    631633
    632 A ``Q`` object (``django.db.models.Q``) is an object used to encapsulate a
     634A ``Q`` object (:class:`django.db.models.Q`) is an object used to encapsulate a
    633635collection of keyword arguments. These keyword arguments are specified as in
    634636"Field lookups" above.
    635637
  • docs/ref/models/fields.txt

     
    844844    current date/time to be chosen.
    845845
    846846    Instead of a dictionary this can also be a :class:`~django.db.models.Q`
    847     object (an object with a :meth:`get_sql` method) for more complex queries.
     847    object (see :ref:`complex_lookups_with_q`) for more complex queries.
    848848
    849849    ``limit_choices_to`` has no effect on the inline FormSets that are created
    850850    to display related objects in the admin.
Back to Top