Github user yhuai commented on a diff in the pull request:
https://github.com/apache/spark/pull/1650#discussion_r15568205
--- Diff: sql/hive/src/main/scala/org/apache/spark/sql/hive/HiveQl.scala ---
@@ -377,6 +378,10 @@ private[hive] object HiveQl {
}
protected def nodeToPlan(node: Node): LogicalPlan = node match {
+ // Special drop table that also uncaches.
+ case Token("TOK_DROPTABLE",
+ Token("TOK_TABNAME",
+ Token(tableName, Nil) :: Nil) :: Nil) => DropTable(tableName)
--- End diff --
Seems we also need to support refer to a table with the format of
`dbName.tableName` and `IF EXISTS`.
An example AST:
The AST tree of `drop table if exists default.src` is
```
TOK_DROPTABLE
TOK_TABNAME
default
src
TOK_IFEXISTS
```
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---