From fff7fc500b3ab0ead49685cbd1310d5b2dfa0972 Mon Sep 17 00:00:00 2001 From: Alexander Barkov Date: Tue, 7 Nov 2017 15:03:58 +0400 Subject: MDEV-10817 CAST(MAX(DATE'2001-01-01') AS TIME) returns a wrong result --- sql/item_func.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'sql/item_func.h') diff --git a/sql/item_func.h b/sql/item_func.h index bee6dc4e524..ef703456818 100644 --- a/sql/item_func.h +++ b/sql/item_func.h @@ -2367,6 +2367,13 @@ public: return sp_result_field->val_decimal(dec_buf); } + bool get_date(MYSQL_TIME *ltime, ulonglong fuzzydate) + { + if (execute()) + return true; + return sp_result_field->get_date(ltime, fuzzydate); + } + String *val_str(String *str) { String buf; -- cgit v1.2.1