Accelarator commented on issue #14101: URL: https://github.com/apache/doris/issues/14101#issuecomment-1309674585
> 重建表走colocation join试下 可以了,重建表走colocation join,使用join on的字段做分桶,7亿左右的数据group by后自关联3.9秒,与预期差不多了,感谢大佬~ ``` SQL CREATE TABLE IF NOT EXISTS test_distribute_by_uid2( `server_timestamp` datetime COMMENT '服务端时间 格式’yyyy-mm-dd hh:mi:ss’', `app_name` varchar(64) , `user_id` bigint , `client_timestamp` datetime , `city` STRING , `province` STRING , `create_time` datetime ) ENGINE=olap DUPLICATE KEY(server_timestamp) COMMENT "test" PARTITION BY RANGE(server_timestamp)() DISTRIBUTED BY HASH(app_name,user_id) BUCKETS 32 PROPERTIES ( 'replication_num' = '1', 'colocate_with' = 'group1', 'dynamic_partition.enable' = 'true', 'dynamic_partition.time_unit' = 'day', 'dynamic_partition.end' = '1', 'dynamic_partition.prefix' = 'p', 'dynamic_partition.buckets' = '32', 'dynamic_partition.create_history_partition' = 'true', 'dynamic_partition.history_partition_num' = '5' ); ```  -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org