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



##########
File path: 
sql/hive/src/main/scala/org/apache/spark/sql/hive/HiveInspectors.scala
##########
@@ -512,6 +527,12 @@ private[hive] trait HiveInspectors {
         _ => constant
       case poi: VoidObjectInspector =>
         _ => null // always be null for void object inspector
+      case ym: WritableConstantHiveIntervalDayTimeObjectInspector =>
+        val constant = 
ym.getWritableConstantValue.asInstanceOf[HiveIntervalDayTime]
+        _ => constant.getTotalSeconds * DateTimeConstants.NANOS_PER_MICROS + 
constant.getNanos

Review comment:
       I didn't get this. You multiply seconds by 1000 which is milliseconds 
and add nanoseconds. Which is obviously wrong (btw day-time interval has 
microsecond precision). Could you fix this and write a test for this piece of 
code, please.




-- 
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:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to