summaryrefslogtreecommitdiff
path: root/docs/ref/models/database-functions.txt
diff options
context:
space:
mode:
Diffstat (limited to 'docs/ref/models/database-functions.txt')
-rw-r--r--docs/ref/models/database-functions.txt11
1 files changed, 11 insertions, 0 deletions
diff --git a/docs/ref/models/database-functions.txt b/docs/ref/models/database-functions.txt
index 20ceadde91..74198ed749 100644
--- a/docs/ref/models/database-functions.txt
+++ b/docs/ref/models/database-functions.txt
@@ -686,6 +686,17 @@ that deal with time-parts can be used with ``TimeField``::
truncate function. It's also registered as a transform on ``DateTimeField`` as
``__date``.
+.. class:: TruncTime(expression, **extra)
+
+.. versionadded:: 1.11
+
+ .. attribute:: lookup_name = 'time'
+ .. attribute:: output_field = TimeField()
+
+``TruncTime`` casts ``expression`` to a time rather than using the built-in SQL
+truncate function. It's also registered as a transform on ``DateTimeField`` as
+``__time``.
+
.. class:: TruncDay(expression, output_field=None, tzinfo=None, **extra)
.. attribute:: kind = 'day'