diff options
author | unknown <igor@rurik.mysql.com> | 2005-09-06 22:20:11 -0700 |
---|---|---|
committer | unknown <igor@rurik.mysql.com> | 2005-09-06 22:20:11 -0700 |
commit | d877cdf3e7fa6c176a2dea418deaa0bb2d9500ff (patch) | |
tree | a15c71fa469ce1f2ad833049715ab009a914378a /mysql-test/t/func_gconcat.test | |
parent | 291d59d4bf1d753fca6d10f1738aff4134e6f9fa (diff) | |
download | mariadb-git-d877cdf3e7fa6c176a2dea418deaa0bb2d9500ff.tar.gz |
func_gconcat.result, func_gconcat.test:
Added test cases for bug #12863.
item_sum.cc, item_sum.h:
Fixed bug #12863.
Added a flag to Item_func_group_concat set to FALSE after
concatenation of the first element of a group.
sql/item_sum.h:
Fixed bug #12863.
Added a flag to Item_func_group_concat set to FALSE after
concatenation of the first element of a group.
sql/item_sum.cc:
Fixed bug #12863.
Added a flag to Item_func_group_concat set to FALSE after
concatenation of the first element of a group.
mysql-test/t/func_gconcat.test:
Added test cases for bug #12863.
mysql-test/r/func_gconcat.result:
Added test cases for bug #12863.
Diffstat (limited to 'mysql-test/t/func_gconcat.test')
-rw-r--r-- | mysql-test/t/func_gconcat.test | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/mysql-test/t/func_gconcat.test b/mysql-test/t/func_gconcat.test index 9e003d19ab9..aa8ce0f4bdc 100644 --- a/mysql-test/t/func_gconcat.test +++ b/mysql-test/t/func_gconcat.test @@ -356,4 +356,20 @@ select * from (select group_concat(a) from t1) t2; select group_concat('x') UNION ALL select 1; drop table t1; +# +# Bug #12863 : missing separators after first empty cancatanated elements +# + +CREATE TABLE t1 (id int, a varchar(9)); +INSERT INTO t1 VALUES + (2, ''), (1, ''), (2, 'x'), (1, 'y'), (3, 'z'), (3, ''); + +SELECT GROUP_CONCAT(a) FROM t1; +SELECT GROUP_CONCAT(a ORDER BY a) FROM t1; + +SELECT GROUP_CONCAT(a) FROM t1 GROUP BY id; +SELECT GROUP_CONCAT(a ORDER BY a) FROM t1 GROUP BY id; + +DROP TABLE t1; + # End of 4.1 tests |