You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2019/12/16 06:35:15 UTC

[GitHub] [spark] cloud-fan commented on a change in pull request #26699: [SPARK-30066][SQL] Support columnar execution on interval types

cloud-fan commented on a change in pull request #26699: [SPARK-30066][SQL] Support columnar execution on interval types
URL: https://github.com/apache/spark/pull/26699#discussion_r358070365
 
 

 ##########
 File path: sql/core/src/main/scala/org/apache/spark/sql/execution/columnar/ColumnType.scala
 ##########
 @@ -705,6 +705,37 @@ private[columnar] case class MAP(dataType: MapType)
   override def clone(v: UnsafeMapData): UnsafeMapData = v.copy()
 }
 
+private[columnar] object CALENDAR_INTERVAL extends ColumnType[CalendarInterval]
+  with DirectCopyColumnType[CalendarInterval] {
+
+  override def dataType: DataType = CalendarIntervalType
+
+  override def defaultSize: Int = 16
+
+  override def actualSize(row: InternalRow, ordinal: Int): Int = 20
 
 Review comment:
   why actual size is different from default size?

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


With regards,
Apache Git Services

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