panbingkun commented on code in PR #46655: URL: https://github.com/apache/spark/pull/46655#discussion_r1610858861
########## connector/docker-integration-tests/src/test/scala/org/apache/spark/sql/jdbc/MySQLIntegrationSuite.scala: ########## @@ -154,30 +154,43 @@ class MySQLIntegrationSuite extends DockerJDBCIntegrationSuite { test("SPARK-47462: Unsigned numeric types") { val df = sqlContext.read.jdbc(jdbcUrl, "unsigned_numbers", new Properties) val rows = df.head() - assert(rows.get(0).isInstanceOf[Short]) - assert(rows.get(1).isInstanceOf[Integer]) - assert(rows.get(2).isInstanceOf[Integer]) - assert(rows.get(3).isInstanceOf[Long]) - assert(rows.get(4).isInstanceOf[BigDecimal]) - assert(rows.get(5).isInstanceOf[BigDecimal]) - assert(rows.get(6).isInstanceOf[Double]) - // Unlike MySQL, MariaDB seems not to distinguish signed and unsigned tinyint(1). val isMaria = jdbcUrl.indexOf("disableMariaDbDriver") == -1 if (isMaria) { + assert(rows.get(0).isInstanceOf[Integer]) + assert(rows.get(1).isInstanceOf[Long]) + assert(rows.get(2).isInstanceOf[Integer]) + assert(rows.get(3).isInstanceOf[BigDecimal]) Review Comment: We can make changes as follows to keep this compatible: <img width="899" alt="image" src="https://github.com/apache/spark/assets/15246973/6c3b04f3-b846-4b2b-84df-3134540cbd89"> If we need to do this, how about making related changes directly in this PR? Or a new seperated PR? -- 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: reviews-unsubscr...@spark.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org