diff options
author | unknown <bar@bar.mysql.r18.ru> | 2002-11-06 15:49:53 +0400 |
---|---|---|
committer | unknown <bar@bar.mysql.r18.ru> | 2002-11-06 15:49:53 +0400 |
commit | b0b72e4d52d525b82f9649cc7d57d647950ec59b (patch) | |
tree | 327d33408ca6f413ce8f595905d090403c11124b /sql/item_timefunc.h | |
parent | 1e63509dfc5828fbd2180d3bc2bbeae0a32e42ee (diff) | |
download | mariadb-git-b0b72e4d52d525b82f9649cc7d57d647950ec59b.tar.gz |
Item->thd_charset() - returns a default charset which should be used
to compose strings appeared without charset context, for example,
in convertion from numer into string type.
Diffstat (limited to 'sql/item_timefunc.h')
-rw-r--r-- | sql/item_timefunc.h | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/sql/item_timefunc.h b/sql/item_timefunc.h index fab8ea9fa9c..de2860d24ef 100644 --- a/sql/item_timefunc.h +++ b/sql/item_timefunc.h @@ -69,7 +69,7 @@ public: double val() { return (double) Item_func_month::val_int(); } String *val_str(String *str) { - str->set(val_int(), my_thd_charset); + str->set(val_int(), thd_charset()); return null_value ? 0 : str; } const char *func_name() const { return "month"; } @@ -177,7 +177,7 @@ public: longlong val_int(); double val() { return (double) val_int(); } String *val_str(String *str) { - str->set(val_int(), my_thd_charset); + str->set(val_int(), thd_charset()); return null_value ? 0 : str; } const char *func_name() const { return "weekday"; } @@ -243,7 +243,7 @@ public: } Field *tmp_table_field(TABLE *t_arg) { - return (!t_arg) ? result_field : new Field_date(maybe_null, name, t_arg, my_thd_charset); + return (!t_arg) ? result_field : new Field_date(maybe_null, name, t_arg, thd_charset()); } }; @@ -261,7 +261,7 @@ public: Field *tmp_table_field(TABLE *t_arg) { return (!t_arg) ? result_field : new Field_datetime(maybe_null, name, - t_arg, my_thd_charset); + t_arg, thd_charset()); } }; @@ -288,7 +288,7 @@ public: Field *tmp_table_field(TABLE *t_arg) { return (!t_arg) ? result_field : - new Field_time(maybe_null, name, t_arg, my_thd_charset); + new Field_time(maybe_null, name, t_arg, thd_charset()); } }; @@ -381,7 +381,7 @@ public: Field *tmp_table_field(TABLE *t_arg) { return (!t_arg) ? result_field : - new Field_time(maybe_null, name, t_arg, my_thd_charset); + new Field_time(maybe_null, name, t_arg, thd_charset()); } }; @@ -446,7 +446,7 @@ public: Field *tmp_table_field(TABLE *t_arg) { return (!t_arg) ? result_field : - new Field_date(maybe_null, name, t_arg, my_thd_charset); + new Field_date(maybe_null, name, t_arg, thd_charset()); } }; @@ -462,7 +462,7 @@ public: Field *tmp_table_field(TABLE *t_arg) { return (!t_arg) ? result_field : - new Field_time(maybe_null, name, t_arg, my_thd_charset); + new Field_time(maybe_null, name, t_arg, thd_charset()); } }; @@ -478,6 +478,6 @@ public: Field *tmp_table_field(TABLE *t_arg) { return (!t_arg) ? result_field : new Field_datetime(maybe_null, name, - t_arg, my_thd_charset); + t_arg, thd_charset()); } }; |