Skip to content

Conversation

@sureshthalamati
Copy link
Contributor

What changes were proposed in this pull request?

This PR throws Unsupported Operation exception for create index, drop index, alter index , lock table , lock database, unlock table, and unlock database operations that are not supported in Spark SQL. Currently these operations are executed executed by Hive.

Error:
spark-sql> drop index my_index on my_table;
Error in query:
Unsupported operation: drop index(line 1, pos 0)

How was this patch tested?

Added test cases to HiveQuerySuite

@yhuai @hvanhovell @andrewor14

@sureshthalamati
Copy link
Contributor Author

This Jira also mentions alter table touch as an unsupported operation. But there is an explicit parser rule for this command , I was not sure if there is work in progress to support it or not ? If there are no plans to support I will update this PR accordingly.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this a non-reserved keyword according to Hive? If it is please add it to the nonReserved rule.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is non-Reserved.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for reviewing the PR, Herman. Added it to the non-Reserved list.

@hvanhovell
Copy link
Contributor

@sureshthalamati thanks for working on this. The ALTER TABLE table TOUCH [PARTITION spec] command has already been implemented.

@SparkQA
Copy link

SparkQA commented Mar 30, 2016

Test build #2709 has finished for PR 12069 at commit 6f46e32.

  • This patch fails Spark unit tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@sureshthalamati
Copy link
Contributor Author

Thanks for the input, Herman. Addressed the review comments , and fixed the test failure in my latest commit.

@andrewor14
Copy link
Contributor

@sureshthalamati can you rebase now?

@sureshthalamati sureshthalamati force-pushed the unsupported_ddl_spark-14133 branch from e3559ec to 31ae9d5 Compare March 31, 2016 18:46
@sureshthalamati
Copy link
Contributor Author

Thanks for reviewing the PR , Andrew. I rebased it.

@andrewor14
Copy link
Contributor

retest this please

@SparkQA
Copy link

SparkQA commented Mar 31, 2016

Test build #54655 has finished for PR 12069 at commit 31ae9d5.

  • This patch fails Spark unit tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@sureshthalamati
Copy link
Contributor Author

The failed test in previous run : org.apache.spark.sql.sources.JsonHadoopFsRelationSuite passes for me on my local machine.

@hvanhovell
Copy link
Contributor

Yeah that is a bit funny. I triggered another build.

@SparkQA
Copy link

SparkQA commented Mar 31, 2016

Test build #2719 has finished for PR 12069 at commit 31ae9d5.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@hvanhovell
Copy link
Contributor

LGTM

@hvanhovell
Copy link
Contributor

Merging to master. Thanks!

@asfgit asfgit closed this in a471c7f Apr 1, 2016
@sureshthalamati
Copy link
Contributor Author

Thanks, Herman.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants