[MCOL-2146] group_concat with distinct concatenates even non-distinct values Created: 2019-02-08 Updated: 2020-02-18 Resolved: 2019-09-27 |
|
| Status: | Closed |
| Project: | MariaDB ColumnStore |
| Component/s: | ExeMgr |
| Affects Version/s: | 1.0.15, 1.1.6, 1.2.2 |
| Fix Version/s: | 1.4.0 |
| Type: | Bug | Priority: | Minor |
| Reporter: | Roman | Assignee: | Daniel Lee (Inactive) |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||||||||||||||
| Sprint: | 2019-06 | ||||||||||||||||||||
| Description |
|
If the group_concat contains distinct together with sorting over non-distinct column CS concatenates distinct values multiple times. Here is the setting:
|
| Comments |
| Comment by Roman [ 2019-02-08 ] | ||
|
IdbOrderBy::Hasher::operator() and IdbOrderBy::Eq::operator() both don't exempt non-distinct columns from calculation when they call Row::hash() and Row:eq() respectively. Hasher and Eq operators must sent down the stack the column count equals with distinct columns count. | ||
| Comment by Daniel Lee (Inactive) [ 2019-09-27 ] | ||
|
Build verified: 1.4.0-1 [dlee@master centos7]$ cat gitversionInfo.txt MariaDB [mytest]> create table cs1 (i bigint, a bigint) engine=columnstore; MariaDB [mytest]> insert into cs1 values (1,2),(1,3),(2,5),(1,42); MariaDB [mytest]> select group_concat(distinct i order by a) s from cs1;
------
------ |