Github user yhuai commented on a diff in the pull request:

    https://github.com/apache/spark/pull/13008#discussion_r62939286
  
    --- Diff: sql/core/src/main/scala/org/apache/spark/sql/SparkSession.scala 
---
    @@ -490,8 +490,8 @@ class SparkSession private(
         // TODO: use MutableProjection when rowRDD is another DataFrame and 
the applied
         // schema differs from the existing schema on any field data type.
         val catalystRows = if (needsConversion) {
    -      val converter = 
CatalystTypeConverters.createToCatalystConverter(schema)
    -      rowRDD.map(converter(_).asInstanceOf[InternalRow])
    +      val encoder = RowEncoder(schema)
    --- End diff --
    
    So, we already do null check in RowEncoder, right?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

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

Reply via email to