This is an automated email from the ASF dual-hosted git repository. morningman pushed a commit to branch branch-1.2-lts in repository https://gitbox.apache.org/repos/asf/doris.git
commit 54af007cb7bf1bb7d91672423be4cbc47523d9bb Author: starocean999 <40539150+starocean...@users.noreply.github.com> AuthorDate: Fri Aug 4 15:21:18 2023 +0800 [fix](planner) fix bug of push conjuncts through second phase agg (#22417) If there is a second phase agg, the output of the 1st phase agg is its intermediate tuple not the output tuple. This pr fix it --- .../suites/correctness_p0/test_distinct_agg.groovy | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/regression-test/suites/correctness_p0/test_distinct_agg.groovy b/regression-test/suites/correctness_p0/test_distinct_agg.groovy index 8c80c9f184..ea2cd1f4a4 100644 --- a/regression-test/suites/correctness_p0/test_distinct_agg.groovy +++ b/regression-test/suites/correctness_p0/test_distinct_agg.groovy @@ -55,4 +55,18 @@ suite("test_distinct_agg") { ''' result([['1', '2023-01-10', 1L]]) } + + sql '''SELECT `b`.`dt` AS `dt` + FROM + (SELECT `dt`AS `dt`, + count(DISTINCT `role_id`) AS `pay_role`, + avg(`cost`) AS `avg_cost` + FROM + (SELECT `k6` AS `dt`, + `k1` AS `role_id`, + sum(CAST(`k2` AS INT)) AS `cost` + FROM `t` + GROUP BY `dt`, `role_id`) a + GROUP BY `dt`) b + WHERE `dt` = '2023-06-18';''' } \ No newline at end of file --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org