diff options
author | bar@bar.mysql.r18.ru <> | 2002-11-06 15:49:53 +0400 |
---|---|---|
committer | bar@bar.mysql.r18.ru <> | 2002-11-06 15:49:53 +0400 |
commit | 9a9e7ce0f4e9f9e60e6f8eb5b5d345c018893635 (patch) | |
tree | 327d33408ca6f413ce8f595905d090403c11124b /sql/item_timefunc.h | |
parent | 8229d282f7767efe4c88294acdb65507fef4079e (diff) | |
download | mariadb-git-9a9e7ce0f4e9f9e60e6f8eb5b5d345c018893635.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()); } }; |