Nikita Fomichev 2024-04-11 13:47:34 +02:00
parent f1428210e6
commit 564cd01c64
2 changed files with 9 additions and 0 deletions

View File

@ -0,0 +1,3 @@
北京 ['北京']
上海 ['北京','上海']
西安 ['北京','上海','西安']

View File

@ -0,0 +1,6 @@
-- https://github.com/ClickHouse/ClickHouse/issues/44039
create table test_window_collate(c1 String, c2 String) engine=MergeTree order by c1;
insert into test_window_collate values('1', '上海');
insert into test_window_collate values('1', '北京');
insert into test_window_collate values('1', '西安');
select c2, groupArray(c2) over (partition by c1 order by c2 asc collate 'zh_Hans_CN') as res from test_window_collate order by c2 asc collate 'zh_Hans_CN';