cloud-fan commented on a change in pull request #31319:
URL: https://github.com/apache/spark/pull/31319#discussion_r564227086
##########
File path: sql/core/src/test/scala/org/apache/spark/sql/SQLQuerySuite.scala
##########
@@ -3868,6 +3868,43 @@ class SQLQuerySuite extends QueryTest with
SharedSparkSession with AdaptiveSpark
assert(unions.size == 1)
}
+
+ test("SPARK-34212 Parquet should read decimals correctly") {
+ // Decimal(2, 1) for INT32-backed decimal, Decimal(17, 2) for INT64-backed
decimal
+ val df = sql("SELECT 1.0 a, CAST(100 AS DECIMAL(17, 2)) b, map(1, 2) c")
+
+ withTempPath { path =>
+ df.write.parquet(path.toString)
+
+ // 1. Complex schema disables vectorization automatically.
Review comment:
Since we have case 2, why do we test case 1? To prove that complex
schema disables vectorization? That's kind of something we already tested well
and we don't need to repeat it here.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]