Skip to content

Conversation

@imback82
Copy link
Contributor

What changes were proposed in this pull request?

Add RepairTableStatement and make REPAIR TABLE go through the same catalog/table resolution framework of v2 commands.

Why are the changes needed?

It's important to make all the commands have the same table resolution behavior, to avoid confusing end-users. e.g.

USE my_catalog
DESC t // success and describe the table t from my_catalog
MSCK REPAIR TABLE t // report table not found as there is no table t in the session catalog

Does this PR introduce any user-facing change?

yes. When running MSCK REPAIR TABLE, Spark fails the command if the current catalog is set to a v2 catalog, or the table name specified a v2 catalog.

How was this patch tested?

New unit tests

@imback82
Copy link
Contributor Author

cc: @cloud-fan @rdblue @viirya

@SparkQA
Copy link

SparkQA commented Oct 18, 2019

Test build #112294 has finished for PR 26168 at commit 6135df9.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds the following public classes (experimental):
  • case class RepairTableStatement(tableName: Seq[String]) extends ParsedStatement

@viirya
Copy link
Member

viirya commented Oct 19, 2019

Thanks! Merging to master.

@viirya viirya closed this in ab92e17 Oct 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants