revans2 commented on code in PR #38739:
URL: https://github.com/apache/spark/pull/38739#discussion_r1028178729
##########
sql/core/src/test/scala/org/apache/spark/sql/DataFrameSuite.scala:
##########
@@ -3532,6 +3532,49 @@ class DataFrameSuite extends QueryTest
}.isEmpty)
}
}
+
+ test("SPARK-41207: Fix BinaryArithmetic with negative scale") {
+ withSQLConf(SQLConf.LEGACY_ALLOW_NEGATIVE_SCALE_OF_DECIMAL_ENABLED.key ->
"true") {
Review Comment:
There are external reasons to not support negative scale decimal values.
ANSI SQL disallows it, which is why SPARK-30252 turned it off by default.
Parquet does not support it, which by the way that appears to be a bug in
`ParquetTable` where it says that they are supported. I'll file an issue for
it.
To me there are two choices we either need to support it fully and start to
work through all of the issues and corner cases to make them work all the time,
or we need to deprecate them and remove them. It has been three years I think
we can move from legacy to deprecated. Having a "solution" with land mines
hidden in it and only a config to protect you is not a good solution at all.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]