diff options
author | bar@bar.mysql.r18.ru <> | 2002-10-30 16:19:43 +0400 |
---|---|---|
committer | bar@bar.mysql.r18.ru <> | 2002-10-30 16:19:43 +0400 |
commit | b43876b9dd5a4e361c458d271110da88eea5d43a (patch) | |
tree | afd6e4ea67b585a5ec68bd069142c6d208822c5a /sql/item_timefunc.h | |
parent | 637b97991d3d1d6ca06f396e7fbdf67f6b876e35 (diff) | |
download | mariadb-git-b43876b9dd5a4e361c458d271110da88eea5d43a.tar.gz |
All String->set() now have charset argument
Diffstat (limited to 'sql/item_timefunc.h')
-rw-r--r-- | sql/item_timefunc.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/sql/item_timefunc.h b/sql/item_timefunc.h index 94e8e6eba43..66c9a1a4438 100644 --- a/sql/item_timefunc.h +++ b/sql/item_timefunc.h @@ -67,7 +67,11 @@ public: Item_func_month(Item *a) :Item_func(a) {} longlong val_int(); double val() { return (double) Item_func_month::val_int(); } - String *val_str(String *str) { str->set(val_int()); return null_value ? 0 : str;} + String *val_str(String *str) + { + str->set(val_int(), my_thd_charset); + return null_value ? 0 : str; + } const char *func_name() const { return "month"; } enum Item_result result_type () const { return INT_RESULT; } void fix_length_and_dec() { decimals=0; max_length=2; maybe_null=1; } @@ -172,7 +176,10 @@ public: :Item_func(a), odbc_type(type_arg) {} longlong val_int(); double val() { return (double) val_int(); } - String *val_str(String *str) { str->set(val_int()); return null_value ? 0 : str;} + String *val_str(String *str) { + str->set(val_int(), my_thd_charset); + return null_value ? 0 : str; + } const char *func_name() const { return "weekday"; } enum Item_result result_type () const { return INT_RESULT; } void fix_length_and_dec() { decimals=0; max_length=1; maybe_null=1; } |