Skip to content

Commit 09296c4

Browse files
author
ashahid
committed
1 parent 0ecbc30 commit 09296c4

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

sql/core/src/main/scala/org/apache/spark/sql/Dataset.scala

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4488,11 +4488,13 @@ private[sql] object EasilyFlattenable {
44884488
} ))) {
44894489
None
44904490
} else {
4491-
val remappedNewProjList = newProjList.map(ne => ne match {
4491+
val remappedNewProjList = newProjList.map(ne => (ne transformUp {
44924492
case attr: AttributeReference => projList.find(
44934493
_.toAttribute.canonicalized == attr.canonicalized).get
4494-
case x => x
4495-
})
4494+
case u: UnresolvedAttribute if u.getTagValue(LogicalPlan.PLAN_ID_TAG).isDefined =>
4495+
u.setTagValue(LogicalPlan.PLAN_ID_TAG, child)
4496+
u
4497+
}).asInstanceOf[NamedExpression])
44964498
Option(p.copy(projectList = remappedNewProjList))
44974499
}
44984500
} else {

0 commit comments

Comments
 (0)