Skip to content

Commit a96885a

Browse files
committed
Use proper name.
1 parent 77ba3a6 commit a96885a

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/PreAnalyzer.scala

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,16 +29,17 @@ class PreAnalyzer(caseSensitive: Boolean = true,
2929
val fixedPoint = FixedPoint(maxIterations)
3030

3131
lazy val batches: Seq[Batch] = Seq(
32-
Batch("ResolveSelfJoin", fixedPoint, ResolveSelfJoin)
32+
Batch("Resolution", fixedPoint, ResolveConflictingAttributes)
3333
)
3434

3535
/**
36-
* Special handling for cases when self-join introduce duplicate expression ids
36+
* Handling the cases in which the attributes of nodes are conflicting
3737
*/
38-
object ResolveSelfJoin extends Rule[LogicalPlan] {
38+
object ResolveConflictingAttributes extends Rule[LogicalPlan] {
3939
def apply(plan: LogicalPlan): LogicalPlan = plan transformUp {
4040
case p: LogicalPlan if !p.childrenResolved => p
4141

42+
// Special handling for cases when self-join introduce duplicate expression ids
4243
case j @ Join(left, right, _, _) if left.outputSet.intersect(right.outputSet).nonEmpty =>
4344
val conflictingAttributes = left.outputSet.intersect(right.outputSet)
4445
logDebug(s"Conflicting attributes ${conflictingAttributes.mkString(",")} in $j")

0 commit comments

Comments
 (0)