-
Notifications
You must be signed in to change notification settings - Fork 786
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix max and min value for decimal precision greater than 38 #2245
Conversation
@@ -309,7 +309,6 @@ pub const MAX_DECIMAL_FOR_EACH_PRECISION: [i128; 38] = [ | |||
/// `MAX_DECIMAL_FOR_LARGER_PRECISION[p]` holds the maximum integer value | |||
/// that can be stored in [DataType::Decimal256] value of precision `p` > 38 | |||
pub const MAX_DECIMAL_FOR_LARGER_PRECISION: [&str; 38] = [ | |||
"99999999999999999999999999999999999999", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is only 38 digits, it should be 39. 😓
@@ -395,7 +395,6 @@ pub const MIN_DECIMAL_FOR_EACH_PRECISION: [i128; 38] = [ | |||
/// `MIN_DECIMAL_FOR_LARGER_PRECISION[p]` holds the minimum integer value | |||
/// that can be stored in a [DataType::Decimal256] value of precision `p` > 38 | |||
pub const MIN_DECIMAL_FOR_LARGER_PRECISION: [&str; 38] = [ | |||
"-99999999999999999999999999999999999999", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto.
0f2567e
to
abc6041
Compare
Codecov Report
@@ Coverage Diff @@
## master #2245 +/- ##
==========================================
- Coverage 82.30% 82.30% -0.01%
==========================================
Files 240 241 +1
Lines 62436 62437 +1
==========================================
Hits 51391 51391
- Misses 11045 11046 +1
Help us with your feedback. Take ten seconds to tell us how you rate us. |
Benchmark runs are scheduled for baseline = f41fb1c and contender = 281cd79. 281cd79 is a master commit associated with this PR. Results will be available as each benchmark for each run completes. |
(Integration testing for the win!) |
Which issue does this PR close?
Closes #2246.
Rationale for this change
What changes are included in this PR?
Are there any user-facing changes?