summaryrefslogtreecommitdiff
path: root/sql/item_timefunc.h
diff options
context:
space:
mode:
Diffstat (limited to 'sql/item_timefunc.h')
-rw-r--r--sql/item_timefunc.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/sql/item_timefunc.h b/sql/item_timefunc.h
index adc7b2535a9..878179105be 100644
--- a/sql/item_timefunc.h
+++ b/sql/item_timefunc.h
@@ -1184,6 +1184,20 @@ public:
};
+class Item_datetime_from_unixtime_typecast :public Item_datetime_typecast
+{
+ THD *thd;
+public:
+ Item_datetime_from_unixtime_typecast(THD *_thd, Item *a, uint dec_arg):
+ Item_datetime_typecast(_thd, a, dec_arg), thd(_thd) {}
+ const char *func_name() const { return "cast_as_datetime_from_unixtime"; }
+ const char *cast_type() const { return "datetime"; }
+ void fix_length_and_dec();
+ Item *get_copy(THD *thd)
+ { return get_item_copy<Item_datetime_from_unixtime_typecast>(thd, this); }
+};
+
+
class Item_func_makedate :public Item_datefunc
{
bool check_arguments() const