存算分离版本, count(1) over(partition by )不加order by的时候查询报错

麻烦排查以下2个问题

【详述】存算分离版本, count(1) over(partition by )不加order by的时候查询

报错1:执行以下sql报错:

select distinct #distinct_id from (select *,count(1)over(partition by #distinct_id) as cnt from dwd_fact_event_0preset_register_20 where #days = ‘2023-11-09’) t where cnt > 1 limit 10;

排查发现:只要开窗的时候加order by 就可以执行,不加就报错。

报错2:count(1) 替换成 count(decimal类型字段)也会报错,报错为不支持decimal类型
执行sql:

select distinct #distinct_id from (select *,count(pay_money)over(partition by #distinct_id) as cnt from dwd_fact_event_0preset_paid_17 where #days = ‘2023-11-09’) t where cnt > 1 limit 10;

【业务影响】
【StarRocks版本】sr的版本是 branch-3.1-de6c740
【集群规模】3fe + 10be 存算分离版本

1.贴下fe.log中的完整异常栈和 怎么获取query_dump文件

你好, 问题已经定位. 如果需要临时规避请set cbo_push_down_distinct_below_window = false

确实,设置成false后,两个问题都可以正常执行。这个在那个版本发布呢?

3.1.15这个版本吧

大佬,我们升级到3.1.5,目前看, set cbo_push_down_distinct_below_window = true 后还是有这个问题,麻烦确认下那个版本修复

sorry, 没赶上发版本…

大佬,3.1.6有修复吗?

嗯合入了