shivsood commented on a change in pull request #24969: [SPARK-28151] ByteType, 
ShortType and FloatTypes are not correctly mapped for read/write of SQLServer 
tables
URL: https://github.com/apache/spark/pull/24969#discussion_r298917941
 
 

 ##########
 File path: sql/core/src/test/scala/org/apache/spark/sql/jdbc/JDBCSuite.scala
 ##########
 @@ -895,6 +895,24 @@ class JDBCSuite extends QueryTest
       "BIT")
     
assert(msSqlServerDialect.getJDBCType(BinaryType).map(_.databaseTypeDefinition).get
 ==
       "VARBINARY(MAX)")
+    
assert(msSqlServerDialect.getJDBCType(ByteType).map(_.databaseTypeDefinition).get
 ==
+      "TINYINT")
+
+    
assert(msSqlServerDialect.getJDBCType(ShortType).map(_.databaseTypeDefinition).get
 ==
+      "SMALLINT")
+  }
+
+  test("MsSqlServerDialect catalyst type mapping") {
 
 Review comment:
   @wangyum Thanks for pointing me to MsSqlServerIntegration.  Agree that's a 
good place to add these test. Looks like these test spin up a SQL server for 
test. Is this run in CI? Any pointers to how to run these test.

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


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to