Loading mysql-test/r/func_concat.result +6 −0 Original line number Diff line number Diff line Loading @@ -26,3 +26,9 @@ FROM t1 GROUP BY new LIMIT 1; number alpha new 1413006 idlfmv 1413006<------------------>idlfmv drop table t1; create table t1 (a char(4), b double, c date, d tinyint(4)); insert into t1 values ('AAAA', 105, '2003-03-01', 1); select * from t1 where concat(A,C,B,D) = 'AAAA2003-03-011051'; a b c d AAAA 105 2003-03-01 1 drop table t1; mysql-test/t/func_concat.test +9 −0 Original line number Diff line number Diff line Loading @@ -25,3 +25,12 @@ FROM t1 GROUP BY new LIMIT 1; SELECT number, alpha, CONCAT_WS('<------------------>',number,alpha) AS new FROM t1 GROUP BY new LIMIT 1; drop table t1; # # Bug #5540: a problem with double type # create table t1 (a char(4), b double, c date, d tinyint(4)); insert into t1 values ('AAAA', 105, '2003-03-01', 1); select * from t1 where concat(A,C,B,D) = 'AAAA2003-03-011051'; drop table t1; sql/item_strfunc.cc +2 −1 Original line number Diff line number Diff line Loading @@ -290,6 +290,7 @@ String *Item_func_concat::val_str(String *str) str->append(*res2); } res= str; use_as_buff= &tmp_value; } else if (res == &tmp_value) { Loading Loading
mysql-test/r/func_concat.result +6 −0 Original line number Diff line number Diff line Loading @@ -26,3 +26,9 @@ FROM t1 GROUP BY new LIMIT 1; number alpha new 1413006 idlfmv 1413006<------------------>idlfmv drop table t1; create table t1 (a char(4), b double, c date, d tinyint(4)); insert into t1 values ('AAAA', 105, '2003-03-01', 1); select * from t1 where concat(A,C,B,D) = 'AAAA2003-03-011051'; a b c d AAAA 105 2003-03-01 1 drop table t1;
mysql-test/t/func_concat.test +9 −0 Original line number Diff line number Diff line Loading @@ -25,3 +25,12 @@ FROM t1 GROUP BY new LIMIT 1; SELECT number, alpha, CONCAT_WS('<------------------>',number,alpha) AS new FROM t1 GROUP BY new LIMIT 1; drop table t1; # # Bug #5540: a problem with double type # create table t1 (a char(4), b double, c date, d tinyint(4)); insert into t1 values ('AAAA', 105, '2003-03-01', 1); select * from t1 where concat(A,C,B,D) = 'AAAA2003-03-011051'; drop table t1;
sql/item_strfunc.cc +2 −1 Original line number Diff line number Diff line Loading @@ -290,6 +290,7 @@ String *Item_func_concat::val_str(String *str) str->append(*res2); } res= str; use_as_buff= &tmp_value; } else if (res == &tmp_value) { Loading