cloud-fan commented on a change in pull request #25747: [SPARK-29039][SQL] 
centralize the catalog and table lookup logic
URL: https://github.com/apache/spark/pull/25747#discussion_r322865163
 
 

 ##########
 File path: 
sql/core/src/main/scala/org/apache/spark/sql/execution/datasources/DataSourceResolution.scala
 ##########
 @@ -164,28 +140,12 @@ case class DataSourceResolution(
         s"Delete from tables is not supported using the legacy / v1 Spark 
external catalog" +
             s" API. Identifier: $table.")
 
-    case delete: DeleteFromStatement =>
-      val relation = UnresolvedRelation(delete.tableName)
-      val aliased = delete.tableAlias.map(SubqueryAlias(_, 
relation)).getOrElse(relation)
-      DeleteFromTable(aliased, delete.condition)
+    case ShowNamespacesStatement(None, pattern) if defaultCatalog.isEmpty =>
 
 Review comment:
   I found this problem while refactoring the catalog lookup logic. If no 
catalog is specified and default catalog is not set, we should fallback to v1 
command which is `ShowDatabasesCommand` in this case.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to