summaryrefslogtreecommitdiff
path: root/sql/item_strfunc.h
diff options
context:
space:
mode:
authorigor@rurik.mysql.com <>2004-02-19 01:09:54 -0800
committerigor@rurik.mysql.com <>2004-02-19 01:09:54 -0800
commitf18e0068ba81c909b28ed4b66ee6d84f7e4ad932 (patch)
treeaa627335f475f099e0d352b39af4e24d6e1ac189 /sql/item_strfunc.h
parent09fa16424a9d5e35b1b7abbc912b0bdfc105f15f (diff)
parent1be033f62cc7decdc0867ad44aaebd87b3f74884 (diff)
downloadmariadb-git-f18e0068ba81c909b28ed4b66ee6d84f7e4ad932.tar.gz
Manual merge
Diffstat (limited to 'sql/item_strfunc.h')
-rw-r--r--sql/item_strfunc.h19
1 files changed, 4 insertions, 15 deletions
diff --git a/sql/item_strfunc.h b/sql/item_strfunc.h
index 2bc37de86d8..04009fe10e1 100644
--- a/sql/item_strfunc.h
+++ b/sql/item_strfunc.h
@@ -95,7 +95,6 @@ class Item_func_concat_ws :public Item_str_func
public:
Item_func_concat_ws(Item *a,List<Item> &list)
:Item_str_func(list),separator(a) {}
- ~Item_func_concat_ws() { delete separator; }
String *val_str(String *);
void fix_length_and_dec();
void update_used_tables();
@@ -409,7 +408,6 @@ class Item_func_make_set :public Item_str_func
public:
Item_func_make_set(Item *a,List<Item> &list) :Item_str_func(list),item(a) {}
- ~Item_func_make_set() { delete item; }
String *val_str(String *str);
bool fix_fields(THD *thd, TABLE_LIST *tlist, Item **ref)
{
@@ -528,7 +526,8 @@ public:
void fix_length_and_dec()
{
collation.set(default_charset());
- decimals=0; max_length=args[0]->max_length*2;
+ decimals=0;
+ max_length=args[0]->max_length*2*collation.collation->mbmaxlen;
}
};
@@ -628,16 +627,6 @@ public:
void print(String *str) { print_op(str); }
};
-class Item_func_conv_charset3 :public Item_str_func
-{
-public:
- Item_func_conv_charset3(Item *arg1,Item *arg2,Item *arg3)
- :Item_str_func(arg1,arg2,arg3) {}
- String *val_str(String *);
- void fix_length_and_dec();
- const char *func_name() const { return "convert"; }
-};
-
class Item_func_charset :public Item_str_func
{
public:
@@ -646,8 +635,8 @@ public:
const char *func_name() const { return "charset"; }
void fix_length_and_dec()
{
- max_length=40; // should be enough
collation.set(system_charset_info);
+ max_length= 64 * collation.collation->mbmaxlen; // should be enough
};
};
@@ -659,8 +648,8 @@ public:
const char *func_name() const { return "collation"; }
void fix_length_and_dec()
{
- max_length=40; // should be enough
collation.set(system_charset_info);
+ max_length= 64 * collation.collation->mbmaxlen; // should be enough
};
};