summaryrefslogtreecommitdiff
path: root/sql/item_timefunc.h
diff options
context:
space:
mode:
authorAlexander Barkov <bar@mariadb.com>2018-11-16 19:18:17 +0400
committerAlexander Barkov <bar@mariadb.com>2018-11-17 10:14:44 +0400
commitd2ba9edd664e27a97aff1c73da5717d6157789d4 (patch)
tree59ebc89ac84a7fc5e328f8d16f025c7b7c744b99 /sql/item_timefunc.h
parentf92d223fe21485c83c71efe9116c02046f3d3b46 (diff)
downloadmariadb-git-d2ba9edd664e27a97aff1c73da5717d6157789d4.tar.gz
MDEV-17740 Extend EXTRACT(x AS DAY*) to understand long time intervals
Diffstat (limited to 'sql/item_timefunc.h')
-rw-r--r--sql/item_timefunc.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/sql/item_timefunc.h b/sql/item_timefunc.h
index d2a4e87a3d1..45f10659a76 100644
--- a/sql/item_timefunc.h
+++ b/sql/item_timefunc.h
@@ -993,12 +993,12 @@ class Item_extract :public Item_int_func,
EXTRACT(DAY FROM '-24:00:00') -> -1
*/
set_handler(handler_by_length(max_length= length + 1/*sign*/, 11));
- m_date_mode= date_mode_t(0);
+ m_date_mode= TIME_INTERVAL_DAY;
}
void set_time_length(uint32 length)
{
set_handler(handler_by_length(max_length= length + 1/*sign*/, 11));
- m_date_mode= TIME_TIME_ONLY;
+ m_date_mode= TIME_INTERVAL_hhmmssff;
}
public:
const interval_type int_type; // keep it public