summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Graham <timograham@gmail.com>2017-02-27 10:07:24 -0500
committerTim Graham <timograham@gmail.com>2017-02-27 10:07:24 -0500
commit6b00af50146335485d8414c42efec7d8dd5397fc (patch)
tree2fb722adfd6161894a17770608bd2edb42df6341
parent82026d61a383d07cd840a0d30443ee66bd99798b (diff)
Refs #27802 -- Corrected BaseDatabaseOperations.datetime_extract/trunc_sql() docstrings.
-rw-r--r--django/db/backends/base/operations.py15
1 files changed, 7 insertions, 8 deletions
diff --git a/django/db/backends/base/operations.py b/django/db/backends/base/operations.py
index 22beb0d417..a372129fb8 100644
--- a/django/db/backends/base/operations.py
+++ b/django/db/backends/base/operations.py
@@ -107,20 +107,19 @@ class BaseDatabaseOperations:
def datetime_extract_sql(self, lookup_type, field_name, tzname):
"""
- Given a lookup_type of 'year', 'month', 'day', 'hour', 'minute' or
- 'second', returns the SQL that extracts a value from the given
- datetime field field_name, and a tuple of parameters.
+ Given a lookup_type of 'year', 'month', 'day', 'hour', 'minute', or
+ 'second', return the SQL that extracts a value from the given
+ datetime field field_name.
"""
raise NotImplementedError('subclasses of BaseDatabaseOperations may require a datetime_extract_sql() method')
def datetime_trunc_sql(self, lookup_type, field_name, tzname):
"""
- Given a lookup_type of 'year', 'month', 'day', 'hour', 'minute' or
- 'second', returns the SQL that truncates the given datetime field
- field_name to a datetime object with only the given specificity, and
- a tuple of parameters.
+ Given a lookup_type of 'year', 'month', 'day', 'hour', 'minute', or
+ 'second', return the SQL that truncates the given datetime field
+ field_name to a datetime object with only the given specificity.
"""
- raise NotImplementedError('subclasses of BaseDatabaseOperations may require a datetime_trunk_sql() method')
+ raise NotImplementedError('subclasses of BaseDatabaseOperations may require a datetime_trunc_sql() method')
def time_trunc_sql(self, lookup_type, field_name):
"""