MaxGekk commented on a change in pull request #32345:
URL: https://github.com/apache/spark/pull/32345#discussion_r621261755



##########
File path: 
sql/hive-thriftserver/src/main/scala/org/apache/spark/sql/hive/thriftserver/SparkGetColumnsOperation.scala
##########
@@ -171,8 +171,8 @@ private[hive] class SparkGetColumnsOperation(
     case BooleanType => java.sql.Types.BOOLEAN
     case ByteType => java.sql.Types.TINYINT
     case ShortType => java.sql.Types.SMALLINT
-    case IntegerType => java.sql.Types.INTEGER
-    case LongType => java.sql.Types.BIGINT
+    case IntegerType | YearMonthIntervalType => java.sql.Types.INTEGER
+    case LongType | DayTimeIntervalType => java.sql.Types.BIGINT

Review comment:
       See the PR https://github.com/apache/spark/pull/32121. We should return 
strings. Since there is no appropriate type in `java.sql.*` for intervals. I 
believe we should return the same as for `CalendarIntervalType` - 
`java.sql.Types.OTHER`.
   
   @beliefer Could you handle `YearMonthIntervalType` and `DayTimeIntervalType` 
separately, and return `java.sql.Types.OTHER`




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

Reply via email to