Terry Kim created SPARK-30248:
---------------------------------
Summary: DROP TABLE doesn't work if session catalog name is
provided
Key: SPARK-30248
URL: https://issues.apache.org/jira/browse/SPARK-30248
Project: Spark
Issue Type: Bug
Components: SQL
Affects Versions: 3.0.0
Reporter: Terry Kim
If a table name is qualified with session catalog name ("spark_catalog"), the
DROP TABLE command fails.
For example, the following
{code:java}
sql("CREATE TABLE tbl USING json AS SELECT 1 AS i")
sql(s"DROP TABLE spark_catalog.tbl")
{code}
fails with:
{code:java}
org.apache.spark.sql.catalyst.analysis.NoSuchDatabaseException: Database
'spark_catalog' not found;
at
org.apache.spark.sql.catalyst.catalog.ExternalCatalog.requireDbExists(ExternalCatalog.scala:42)
at
org.apache.spark.sql.catalyst.catalog.ExternalCatalog.requireDbExists$(ExternalCatalog.scala:40)
at
org.apache.spark.sql.catalyst.catalog.InMemoryCatalog.requireDbExists(InMemoryCatalog.scala:45)
at
org.apache.spark.sql.catalyst.catalog.InMemoryCatalog.tableExists(InMemoryCatalog.scala:336)
{code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]