manuzhang commented on code in PR #19277:
URL: https://github.com/apache/iceberg/pull/19277#discussion_r4802196620


##########
spark/v4.1/spark-extensions/src/main/scala/org/apache/spark/sql/catalyst/analysis/ResolveViews.scala:
##########
@@ -84,6 +95,42 @@ case class ResolveViews(spark: SparkSession) extends 
Rule[LogicalPlan] with Look
         rewritten = true)
   }
 
+  private def hasViewColumnByOrdinal(project: Project): Boolean =
+    
project.projectList.exists(_.exists(_.isInstanceOf[GetViewColumnByOrdinal]))
+
+  private def resolveViewColumn(
+      column: GetViewColumnByOrdinal,
+      output: Seq[Attribute]): Attribute = {
+    val actualName = output.lift(column.ordinal).map(_.name)
+    if (!column.queryColumnNamesMatchSchema && actualName.isDefined &&

Review Comment:
   Does `queryColumnNamesMatchSchema` have the same meaning here and at line 
120?



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to