rdblue commented on code in PR #9343: URL: https://github.com/apache/iceberg/pull/9343#discussion_r1452826597
########## spark/v3.5/spark-extensions/src/main/scala/org/apache/spark/sql/execution/datasources/v2/ExtendedDataSourceV2Strategy.scala: ########## @@ -90,9 +94,20 @@ case class ExtendedDataSourceV2Strategy(spark: SparkSession) extends Strategy wi case OrderAwareCoalesce(numPartitions, coalescer, child) => OrderAwareCoalesceExec(numPartitions, coalescer, planLater(child)) :: Nil + case RenameTable(ResolvedV2View(oldCatalog: ViewCatalog, oldIdent), newName, isView@true) => + val newIdent = Spark3Util.catalogAndIdentifier(spark, newName.toList.asJava) + if (oldCatalog.name != newIdent.catalog().name()) { + cannotMoveViewBetweenCatalogs(oldCatalog.name, newIdent.catalog().name()) + } + RenameV2ViewExec(oldCatalog, oldIdent, newIdent.identifier()) :: Nil + case _ => Nil } + private def cannotMoveViewBetweenCatalogs(oldCatalog: String, newCatalog: String): Throwable = Review Comment: Why have a method for a one-line implementation? -- 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: issues-unsubscr...@iceberg.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org For additional commands, e-mail: issues-h...@iceberg.apache.org