Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
1.2.3
-
None
-
2019-05, 2019-06
Description
See the following example below:
The first query produces correct numbers.
In the second query, all the sums over windows are 100 times too small!!
If we create an InnoDB table, there is no issue
CREATE TABLE `bug_cs` (
`c` decimal(5,2) DEFAULT NULL
) ENGINE=columnstore;
INSERT INTO `bug_cs`
(`c`)
VALUES (2.05), (5.44),(3.04);
select c,sum(c) over(), sum(c) over w1, sum(c) over w2 from bug_cs
WINDOW `w1` as (),`w2` as (rows between unbounded preceding and current row);
select c,sum(c) over(), sum(c) over w1, sum(c) over w2 from
(select
sum(c) as c
from
bug_cs
) t WINDOW `w1` as (),`w2` as (rows between unbounded preceding and current row);