关于DBlink与游标一个问题

huangshy85 2011-12-20 10:36:41
cursor c_getwodetail is
select distinct xwt.wip_entity_name
from xxwip_wrotosfc_temp@prod xwt
where xwt.insorupd_flag in ('I', 'U', 'R')
and xwt.organization_id = 2083
order by xwt.wip_entity_name;

for r_wrodetail in c_getwodetail loop
if tres is null then
--if Download Success then update flag in ERP
begin
update xxwip_wrotosfc_temp@prod
set insorupd_flag = null
where insorupd_flag in ('I', 'U', 'R')
and wip_entity_name = r_wrodetail.wip_entity_name;
commit;
exception
when others then
rollback;
end;
end if;
tres := null;
end loop;

相关代码如上。
想问一下各位大虾,通过DBlink连接远程数据库的游标中多次对该表进行Commit或者Rollback是否有问题。
因为只要网络不稳定,每次数据库都因游标内的SQL导致ORA-07445内部错误,错误信息如下:


Thu Dec 08 14:50:54 2011
Thread 1 advanced to log sequence 41366
Current log# 3 seq# 41366 mem# 0: T:\ORACLE\xxDB\REDO03.LOG
Thu Dec 08 14:51:09 2011
Errors in file t:\oracle\bdump\xxdb_j001_2528.trc:
ORA-07445: exception encountered: core dump [ACCESS_VIOLATION] [_kpnfch+224] [PC:0xF986B4] [ADDR:0x84] [UNABLE_TO_READ] []

Trac 文件如下:
ksedmp: internal or fatal error
ORA-07445: exception encountered: core dump [ACCESS_VIOLATION] [_kpnfch+224] [PC:0xF986B4] [ADDR:0x84] [UNABLE_TO_READ] []
Current SQL statement for this session:
SELECT DISTINCT XWT.WIP_ENTITY_NAME FROM XXWIP_WROTOSFC_TEMP@PROD XWT WHERE XWT.INSORUPD_FLAG IN ('I', 'U','R') AND XWT.ORGANIZATION_ID = 2083 ORDER BY XWT.WIP_ENTITY_NAME
----- PL/SQL Call Stack -----
object line object
handle number name
4A3AE7F0 80 procedure
xx.WO_WRO
4A126AAC 1 anonymous block
----- Call Stack Trace -----
calling call entry argument values in hex
location type point (? means dubious value)
-------------------- -------- -------------------- ----------------------------
_kpnfch+224 00000000
__VInfreq__opifch2+ CALLrel _kpnfch+0
。。。。。。。。

请各位高手指点....
...全文
183 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
huangshy85 2011-12-21
  • 打赏
  • 举报
回复
经典案例都没有人帮忙分析?
huangshy85 2011-12-20
  • 打赏
  • 举报
回复
没有人懂吗?在线等高手

3,491

社区成员

发帖
与我相关
我的任务
社区描述
Oracle 高级技术相关讨论专区
社区管理员
  • 高级技术社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧