与DBLINK有关的ORA-02050/ORA-02051错误

今天在插入通过DBLINK取得的数据到本地库时,insert正常,但commit就碰到ORA-02050/ORA-02051错误,类似如下:
ORA-02050: 事务处理 9.17.23660 已回退, 某些远程数据库可能有问题
ORA-02051: 同一事务处理中的另一会话或分支失败或已完成

通过一番搜索,最终确定问题在本地库的表上存在MV LOG所致,于是想到通过建立全局临时表(create global temporary table……)的方式来处理问题,但实践证明这是不行的:
create global temporary table xx as select * from x where 1=2;
insert into xx select * from x@remote;
insert into x select * from xx;
--以上三步都成功,并且都能插入正确的记录数
commit;
--ORA-02050/ORA-02051错误再度出现

于是,只好老老实实用普通表
create table xx as select * from x where 1=2;
insert into xx select * from x@remote;
insert into x select * from xx;
--以上三步都成功,并且都能插入正确的记录数
commit;
--这次这步也成功了
delete from xx;
commit;
--已成功删除普通临时表里的数据。

最后,问题搞定。
请使用浏览器的分享功能分享到微信等