You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "richardc-db (via GitHub)" <gi...@apache.org> on 2023/07/21 04:04:45 UTC

[GitHub] [spark] richardc-db commented on a diff in pull request #42083: [SPARK-44488][SQL] Support deserializing long types when creating `Metadata` object from JObject

richardc-db commented on code in PR #42083:
URL: https://github.com/apache/spark/pull/42083#discussion_r1270203763


##########
sql/catalyst/src/main/scala/org/apache/spark/sql/types/Metadata.scala:
##########
@@ -137,6 +137,8 @@ object Metadata {
     jObj.obj.foreach {
       case (key, JInt(value)) =>
         builder.putLong(key, value.toLong)
+      case (key, JLong(value)) =>
+        builder.putLong(key, value.toLong)
       case (key, JDouble(value)) =>
         builder.putDouble(key, value)
       case (key, JBool(value)) =>

Review Comment:
   Sure, added a case for Longs in 



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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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