cloud-fan commented on code in PR #49445: URL: https://github.com/apache/spark/pull/49445#discussion_r1931442784
########## sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/ResolveCatalogs.scala: ########## @@ -73,28 +94,39 @@ class ResolveCatalogs(val catalogManager: CatalogManager) } } - private def resolveVariableName(nameParts: Seq[String]): ResolvedIdentifier = { - def ident: Identifier = Identifier.of(Array(CatalogManager.SESSION_NAMESPACE), nameParts.last) - if (nameParts.length == 1) { + private def resolveCreateVariableName(nameParts: Seq[String]): ResolvedIdentifier = { + val ident = SqlScriptingLocalVariableManager.get() + .getOrElse(catalogManager.tempVariableManager) + .createIdentifier(nameParts.last) Review Comment: An `Identifier` is already created, we can directly return `ResolvedIdentifier(FakeSystemCatalog, ident)` here. -- 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: reviews-unsubscr...@spark.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org