Github user davies commented on a diff in the pull request:
https://github.com/apache/spark/pull/7480#discussion_r35158478
--- Diff:
sql/core/src/main/scala/org/apache/spark/sql/execution/rowFormatConverters.scala
---
@@ -93,11 +96,19 @@ private[sql] object EnsureRowFormats extends
Rule[SparkPlan] {
}
case operator: SparkPlan if handlesBothSafeAndUnsafeRows(operator) =>
if (operator.children.map(_.outputsUnsafeRows).toSet.size != 1) {
- // If this operator's children produce both unsafe and safe rows,
then convert everything
- // to unsafe rows
- operator.withNewChildren {
- operator.children.map {
- c => if (!c.outputsUnsafeRows) ConvertToUnsafe(c) else c
+ // If this operator's children produce both unsafe and safe rows,
+ // convert everything unsafe rows if all the schema of them are
support by UnsafeRow
+ if (operator.children.forall(c =>
UnsafeProjection.canSupport(c.schema))) {
--- End diff --
ping @JoshRosen
---
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 [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]