You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Decimal division compatibility mode with spark #7301
And @tustvold notes For people looking to emulate spark which only supports precision up to 38, casting to Decimal256 and then truncating down to Decimal128 will be equivalent, and is what a precision loss arithmetic kernel would do
Describe the solution you'd like
If anyone needs spark compatible decimal division rules, I suggest:
Add a new config option
Apply the rewrite suggested by @tustvold (cast to Decimal256, divide, and then cast to Decimal128) as an AnalyzerRule
Describe alternatives you've considered
See ticket -- we discussed at length changing the semantics of division in arrow-rs and concluded there was no one agreed upon ideal behavior
Activity
alamb commentedon Aug 16, 2023
I don't think we should implement this unless a user actually needs it, but I wanted to summarize the conversation on #6832