diff options
Diffstat (limited to 'mysql-test')
-rw-r--r-- | mysql-test/r/func_concat.result | 13 | ||||
-rw-r--r-- | mysql-test/t/func_concat.test | 24 |
2 files changed, 37 insertions, 0 deletions
diff --git a/mysql-test/r/func_concat.result b/mysql-test/r/func_concat.result new file mode 100644 index 00000000000..75ee8f2bf79 --- /dev/null +++ b/mysql-test/r/func_concat.result @@ -0,0 +1,13 @@ +number alpha new +1413006 idlfmv 1413006<---->idlfmv +1413065 smpsfz 1413065<---->smpsfz +1413127 sljrhx 1413127<---->sljrhx +1413304 qerfnd 1413304<---->qerfnd +new +1413006<---->idlfmv +number alpha new +1413006 idlfmv 1413006<->idlfmv +number alpha new +1413006 idlfmv 1413006-idlfmv-idlfmv-idlfmv-idlfmv-idlfmv-idlfmv-idlfmv +number alpha new +1413006 idlfmv 1413006<------------------>idlfmv diff --git a/mysql-test/t/func_concat.test b/mysql-test/t/func_concat.test new file mode 100644 index 00000000000..d6da1d6a603 --- /dev/null +++ b/mysql-test/t/func_concat.test @@ -0,0 +1,24 @@ +# +# Test of problem with CONCAT_WS() and long separators. +# + +DROP TABLE IF EXISTS t1; +CREATE TABLE t1 ( number INT NOT NULL, alpha CHAR(6) NOT NULL ); +INSERT INTO t1 VALUES (1413006,'idlfmv'), +(1413065,'smpsfz'),(1413127,'sljrhx'),(1413304,'qerfnd'); + +SELECT number, alpha, CONCAT_WS('<---->',number,alpha) AS new +FROM t1 GROUP BY number; + +SELECT CONCAT_WS('<---->',number,alpha) AS new +FROM t1 GROUP BY new LIMIT 1; + +SELECT number, alpha, CONCAT_WS('<->',number,alpha) AS new +FROM t1 GROUP BY new LIMIT 1; + +SELECT number, alpha, CONCAT_WS('-',number,alpha,alpha,alpha,alpha,alpha,alpha,alpha) AS new +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; |