Attempt to do update or delete on table db1.table1 that is not transactional解决
在datagrip尝试对hive中的表格进行删除,碰到了这么个问题
Attempt to do update or delete on table db1.table1 that is not transactional
官方依据是[1],也就是说支持事务操作需要设置一大堆东西.
根据[2][3]配置完后,
记得重启元数据服务,
重启hiveserver2
重启yarn timelineserver
重启时都新开终端。
上述配置完后,应该是可以了。
但是也只是可能而已。
如果hive中进行delete的时候卡住,注意检查yarn界面是不是资源占满了。
测试:
①use db1;
②create table t1(id int, name string)
clustered by (id) into 8 buckets
stored as orc TBLPROPERTIES (‘transactional’=‘true’);
③
insert into t1 values (1,‘aaa’);
insert into t1 values (2,‘bbb’);
④
update t1 set name=‘ccc’ where id=1;
delete from t1 where id=2;
完整Hive配置:
https://gitee.com/appleyuchi/cluster_configuration/blob/master/spark3.0.0-hadoop3.2.1离线多机集群配置-完成/apache-hive-3.0.0-bin-完成/conf/hive-site.xml
Reference:
[1]Hive Transactions
[2]hive0.14-insert、update、delete操作测试
[3]CDH5.4.10 在Hive上执行Update,Delete操作报错Attempt to do update or
总结
以上是生活随笔为你收集整理的Attempt to do update or delete on table db1.table1 that is not transactional解决的全部内容,希望文章能够帮你解决所遇到的问题。
- 上一篇: Requested resource=<
- 下一篇: datagrip防止xx后弹窗