summaryrefslogtreecommitdiff
path: root/docs/db-api.txt
diff options
context:
space:
mode:
authorGeorg Bauer <gb@hugo.westfalen.de>2005-10-06 10:04:07 +0000
committerGeorg Bauer <gb@hugo.westfalen.de>2005-10-06 10:04:07 +0000
commitcb09e10eb2634243f25ae61e439a71ca47d98884 (patch)
tree9bcf21f1bba2c50d0fe20fa40aad56a64bc75499 /docs/db-api.txt
parent04a66b6e55e77c60c8860c2122fb2036438d4c4f (diff)
i18n: merged r776:r786 from trunk
git-svn-id: http://code.djangoproject.com/svn/django/branches/i18n@787 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'docs/db-api.txt')
-rw-r--r--docs/db-api.txt5
1 files changed, 5 insertions, 0 deletions
diff --git a/docs/db-api.txt b/docs/db-api.txt
index e0885da8f0..8a02437aaa 100644
--- a/docs/db-api.txt
+++ b/docs/db-api.txt
@@ -572,6 +572,9 @@ object in the result list is "truncated" to the given ``type``.
* ``"month"`` returns a list of all distinct year/month values for the field.
* ``"day"`` returns a list of all distinct year/month/day values for the field.
+Additional, optional keyword arguments, in the format described in
+"Field lookups" above, are also accepted.
+
Here's an example, using the ``Poll`` model defined above::
>>> from datetime import datetime
@@ -587,6 +590,8 @@ Here's an example, using the ``Poll`` model defined above::
[datetime.datetime(2005, 2, 1), datetime.datetime(2005, 3, 1)]
>>> polls.get_pub_date_list('day')
[datetime.datetime(2005, 2, 20), datetime.datetime(2005, 3, 20)]
+ >>> polls.get_pub_date_list('day', question__contains='name')
+ [datetime.datetime(2005, 3, 20)]
``get_FOO_list()`` also accepts an optional keyword argument ``order``, which
should be either ``"ASC"`` or ``"DESC"``. This specifies how to order the