yaooqinn commented on code in PR #45666:
URL: https://github.com/apache/spark/pull/45666#discussion_r1536005042


##########
sql/core/src/main/scala/org/apache/spark/sql/jdbc/MySQLDialect.scala:
##########
@@ -123,6 +123,8 @@ private case class MySQLDialect() extends JdbcDialect with 
SQLConfHelper {
         // Signed values in [-8388608, 8388607] and unsigned values in [0, 
16777215],
         // both of them fit IntegerType
         Some(IntegerType)
+      case Types.REAL | Types.FLOAT =>
+        if (md.build().getBoolean("isSigned")) Some(FloatType) else 
Some(DoubleType)

Review Comment:
   > do you think we need to warn from our side
   
   Oh, I missed this. This won't be necessary, it looks better to be warned 
when users use DDLs against MySQL DB. In this part, we actually act as a reader



-- 
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]

Reply via email to