我的Hive版本。
hive --version
Hive 1.2.0-mapr-1710
Subversion git://cd4a097b705d/root/opensource/mapr-hive-1.2/dl/mapr-hive-1.2 -r cf159db974ca9f31211937874eef67b0105ef5cd
Compiled by root on Mon Oct 16 20:04:27 UTC 2017
From source with checksum 07ae5487de4e08bffbf15ebbd119411a
已启用配置
set hive.support.concurrency=true;
set hive.txn.manager=org.apache.hadoop.hive.ql.lockmgr.DbTxnManager;
set hive.enforce.bucketing=true;
set hive.exec.dynamic.partition.mode=nostrict;
set hive.compactor.initiator.on=true;
set hive.compactor.worker.threads=1;
表创建
Create table test (
col1 varchar(10), col2 varchar(10)
)
PARTITIONED BY (col3 VARCHAR(1))
CLUSTERED BY (col2) SORTED BY (col2) INTO 2 BUCKETS
stored as orc TBLPROPERTIES('transactional'='true');
然后发出一个简单的更新查询并得到以下错误。
update test set col2='xyz' where col2='abc';
错误
FAILED: SemanticException [Error 10294]: Attempt to do update or delete using transaction manager that does not support these operations.
hive 0.14及更高版本支持酸性特性。对吗?
am正在设置对当前会话的更改。不在xml文件中。
1条答案
按热度按时间zynd9foi1#
是的,hive0.14和更高版本支持acid属性。我认为,您缺少一些配置属性。
看看答案update-on-hive-1-2-1