🤔
min(created_date) AS min_created_date,
create table test_table ( x Int64, cnt UInt32, min_ts SimpleAggregateFunction(min, UInt64) , max_ts SimpleAggregateFunction(max, UInt64) engine = AggregatingMergeTree() order by x; insert into test_table values (1,1,1,1); insert into test_table values (1,1,2,2); optimize table test_table final; select * from test_table;
Так и получится, если поле учавствет в сортировке
Обсуждают сегодня