在HIVE中丢弃表时出错

时间:2017-09-13 06:31:13

标签: hadoop hive hiveql

使用DROP TABLE命令时出错,之后它会为所有其他命令抛出“FAILED:EXECUTION ERROR”。

hive> show databases;
OK
default
practice_db
Time taken: 1.305 seconds, Fetched: 2 row(s)
hive> use default;
OK
Time taken: 0.045 seconds
hive> show tables;
OK
tsunami_deathtoll
tsunami_hightoll
tsunami_japan
Time taken: 0.039 seconds, Fetched: 3 row(s)
hive> drop table tsunami_Japan;
FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask. MetaException(message:For direct MetaStore DB connections, we don't support retries at the client level.)
hive> show tables;
FAILED: SemanticException [Error 10072]: Database does not exist: default
hive> show databases;
FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask. MetaException(message:For direct MetaStore DB connections, we don't support retries at the client level.)
hive> 

如果我使用“退出”,它会正常工作并从头开始直到“DROP TABLE”再次相同.. **注意:表是MANAGED TABLE,使用MySql作为Metastore,HIVE-1.2.2版本

1 个答案:

答案 0 :(得分:0)

我不知道出了什么问题。所以我重新安装了Mysql(我正在练习)并将更新的Mysql连接器jar(mysql-connector-java-5.1.38.jar)复制到hive lib路径。

现在工作正常。