Skip to content

Comments

Improve support for floating point types in Domain translator#2582

Merged
martint merged 4 commits intotrinodb:masterfrom
kasiafi:026DomainManipulationsVsNaN
Jan 22, 2020
Merged

Improve support for floating point types in Domain translator#2582
martint merged 4 commits intotrinodb:masterfrom
kasiafi:026DomainManipulationsVsNaN

Conversation

@kasiafi
Copy link
Member

@kasiafi kasiafi commented Jan 22, 2020

No description provided.

Before this change, a query like
`SELECT col_double FROM t WHERE col_double > 2.0 OR col_double < 5.0`
would return NaN values in the result, which is incorrect.

That was caused by OR-predicate incorrectly translated to Domain.
The union of domains: (col_double > 2.0) and (col_double < 5.0),
neither accepting NaN, resulted in domain "not null", accepting NaN.
The remaining expression was simplified to TRUE.

The issue was fixed by returning the original predicate
as the remaining expression.
@cla-bot cla-bot bot added the cla-signed label Jan 22, 2020
@martint martint merged commit 87557e2 into trinodb:master Jan 22, 2020
@martint martint added this to the 329 milestone Jan 22, 2020
@martint martint mentioned this pull request Jan 22, 2020
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

2 participants