[
https://issues.apache.org/jira/browse/IGNITE-27365?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Konstantin Orlov updated IGNITE-27365:
--------------------------------------
Ignite Flags: Release Notes Required (was: Docs Required,Release Notes
Required)
> Sql. Unexpected result of division of sums of decimals
> ------------------------------------------------------
>
> Key: IGNITE-27365
> URL: https://issues.apache.org/jira/browse/IGNITE-27365
> Project: Ignite
> Issue Type: Bug
> Components: sql ai3
> Affects Versions: 3.1
> Reporter: Konstantin Orlov
> Assignee: Konstantin Orlov
> Priority: Major
> Labels: ignite-3
> Fix For: 3.2
>
> Time Spent: 20m
> Remaining Estimate: 0h
>
> Take a look at the test case:
> {code}
> @Test
> void testDivisionOfSumsOfDecimals() {
> assertQuery("SELECT sum(c1) / sum(c2) FROM (SELECT decimal '10.2382'
> AS c1, decimal '2.06' AS c2)")
> .returns(new BigDecimal("4.97000000000"))
> .check();
> }
> {code}
> It fails because {{BigDecimal.valueOf(4)}} is returned instead.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)