aokolnychyi commented on code in PR #37879:
URL: https://github.com/apache/spark/pull/37879#discussion_r1171761321


##########
sql/core/src/main/scala/org/apache/spark/sql/catalyst/analysis/ResolveSessionCatalog.scala:
##########
@@ -216,19 +216,23 @@ class ResolveSessionCatalog(val catalogManager: 
CatalogManager)
         c
       }
 
-    case DropTable(ResolvedV1TableIdentifier(ident), ifExists, purge) =>
+    case DropTable(ResolvedV1Identifier(ident), ifExists, purge) =>

Review Comment:
   The reason I asked that question is because the PR mentions that V2 tables 
may now skip table lookup. I am not sure how it is possible given the current 
`DropTableExec` implementation that calls `tableExists` before `drop`. The same 
is true for `DropTableCommand`. If I understand correctly, the goal of the PR 
is to avoid one extra lookup. Can we achieve that by referencing tables inside 
`DropTableExec`, instead of an identifier? I guess removing V1 DROP is also an 
option that would work. We may need to check `V2SessionCatalog`. It does an 
extra lookup in drop, which may be not needed.
   
   I created SPARK-43203 for this.



-- 
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