-
Notifications
You must be signed in to change notification settings - Fork 28.3k
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
[3.0][SQL] Revert SPARK-32018 #29450
[3.0][SQL] Revert SPARK-32018 #29450
Conversation
Test build #127501 has finished for PR 29450 at commit
|
retest this please |
+1 to revert to unblock 3.0.1, also see my comment in #29448 (comment) |
Test build #127504 has finished for PR 29450 at commit
|
I'm merging it first as it's safer to revert and keep the behavior the same as before. We can re-try to fix it if we have better ideas. |
### What changes were proposed in this pull request? Revert SPARK-32018 related changes in branch 3.0: #29125 and #29404 ### Why are the changes needed? #29404 is made to fix correctness regression introduced by #29125. However, the behavior of decimal overflow is strange in non-ansi mode: 1. from 3.0.0 to 3.0.1: decimal overflow will throw exceptions instead of returning null on decimal overflow 2. from 3.0.1 to 3.1.0: decimal overflow will return null instead of throwing exceptions. So, this PR proposes to revert both #29404 and #29125. So that Spark will return null on decimal overflow in Spark 3.0.0 and Spark 3.0.1. ### Does this PR introduce _any_ user-facing change? Yes, Spark will return null on decimal overflow in Spark 3.0.1. ### How was this patch tested? Unit tests Closes #29450 from gengliangwang/revertDecimalOverflow. Authored-by: Gengliang Wang <gengliang.wang@databricks.com> Signed-off-by: Wenchen Fan <wenchen@databricks.com>
+1 for the reasoning. Thank you for the decision, @cloud-fan . |
looks good. |
Is it worth describing the current behaviour #29448 (comment) as a known issue in the v3.0.1 release note? |
@maropu This is a long-standing issue in Spark. I think we can mention the latest behavior in the migration guide and release note of 3.1.0. |
…erflow in sum aggregation ### What changes were proposed in this pull request? Add migration guide for decimal value overflow behavior in sum aggregation, introduced in #29026 ### Why are the changes needed? Add migration guide for the behavior changes from 3.0 to 3.1. See also: #29450 (comment) ### Does this PR introduce _any_ user-facing change? No ### How was this patch tested? Build docs and preview: ![image](https://user-images.githubusercontent.com/1097932/90589256-8b7e3380-e192-11ea-8ff1-05a447c20722.png) Closes #29458 from gengliangwang/migrationGuideDecimalOverflow. Authored-by: Gengliang Wang <gengliang.wang@databricks.com> Signed-off-by: Gengliang Wang <gengliang.wang@databricks.com>
What changes were proposed in this pull request?
Revert SPARK-32018 related changes in branch 3.0: #29125 and #29404
Why are the changes needed?
#29404 is made to fix correctness regression introduced by #29125. However, the behavior of decimal overflow is strange in non-ansi mode:
So, this PR proposes to revert both #29404 and #29125. So that Spark will return null on decimal overflow in Spark 3.0.0 and Spark 3.0.1.
Does this PR introduce any user-facing change?
Yes, Spark will return null on decimal overflow in Spark 3.0.1.
How was this patch tested?
Unit tests