srowen commented on a change in pull request #24845: Map ByteType to SMALLINT 
when using JDBC with PostgreSQL
URL: https://github.com/apache/spark/pull/24845#discussion_r294304186
 
 

 ##########
 File path: 
sql/core/src/main/scala/org/apache/spark/sql/jdbc/PostgresDialect.scala
 ##########
 @@ -74,13 +74,13 @@ private object PostgresDialect extends JdbcDialect {
     case FloatType => Some(JdbcType("FLOAT4", Types.FLOAT))
     case DoubleType => Some(JdbcType("FLOAT8", Types.DOUBLE))
     case ShortType => Some(JdbcType("SMALLINT", Types.SMALLINT))
+    case ByteType => Some(JdbcType("SMALLINT", Types.SMALLINT))
 
 Review comment:
   You could fold this case into the one above with `ShortType | ByteType` but 
no big deal

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