ORA-12838: cannot read/modify
发表于:2026-10-31 作者:千家信息网编辑
千家信息网最后更新 2026年10月31日,insert插入数据时报错:SCOTT@prod>insert /*+ append */ into scott.employee select * from scott.employee ;3584
千家信息网最后更新 2026年10月31日ORA-12838: cannot read/modify
insert插入数据时报错:
SCOTT@prod>insert /*+ append */ into scott.employee select * from scott.employee ;3584 rows created.SCOTT@prod>/insert /*+ append */ into scott.employee select * from scott.employee *ERROR at line 1:ORA-12838: cannot read/modify an object after modifying it in parallel
查看表并行度
SQL> select a.degree from dba_tables a where a.table_name='EMPLOYEE';DEGREE-----------1
查看锁信息
SELECT o.object_name, o.owner, l.locked_mode, s.sid, s.serial#, s.logon_time FROM v$locked_object l, dba_objects o, v$session s WHERE l.object_id = o.object_id AND l.session_id = s.sid AND o.object_name = 'EMPLOYEE'; OBJECT_NAME OWNER LOCKED_MODE SID SERIAL# LOGON_TIME---------------- ------- ----------- ---------- ---------- -----------EMPLOYEE SCOTT 6 80 5328 2019/11/24
ora-12838错误
SCOTT@prod>!oerr ora 1283812838, 00000, "cannot read/modify an object after modifying it in parallel"// *Cause: Within the same transaction, an attempt was made to add read or // modification statements on a table after it had been modified in parallel// or with direct load. This is not permitted.// *Action: Rewrite the transaction, or break it up into two transactions:// one containing the initial modification and the second containing the// parallel modification operation.
append会在高水位之上插入数据并且生成较少的redo数据,加快速插入速度的同时会持有一个排它锁,对于执行后未提交的事务容易引发该问题。
MOS相关文档
ORA-12838 with Direct Load Inserts (文档 ID 116494.1)PARALLEL RESTRICTIONS:A transaction can contain multiple parallel DML statements that modilydifferent tables, but after a parallel DML statement modifies a table,NO subsequent serial or Parallel statment (DML or QUERY) can access thesame table again in that transaction.***Each insert in SQL*plus is considered a transaction, while the wholePL/SQL BLOCK is considered a transation.
数据
文档
事务
信息
同时
时报
水位
速度
错误
问题
生成
数据库的安全要保护哪些东西
数据库安全各自的含义是什么
生产安全数据库录入
数据库的安全性及管理
数据库安全策略包含哪些
海淀数据库安全审计系统
建立农村房屋安全信息数据库
易用的数据库客户端支持安全管理
连接数据库失败ssl安全错误
数据库的锁怎样保障安全
深圳市人人互联网科技有限公司
广东猪兼强互联网科技有限公司
深圳九邦互联网科技有限公司
互联网为科技
互联网科技与金融科技
上海挚品互联网科技
互联网科技类展会
小米互联网科技园设置
互联网还是高科技吗
和信科技工业互联网
恒生互联网科技指数跳水
互联网科技平台产品运营
湖北辰鑫科技互联网
同城互联网络科技
马化腾互联网科技教学
互联网科技对化妆品行业
上海旺乐尼互联网科技有限公司
网互联网络科技
知域互联网科技有限公司官网
互联网 科技节活动 微视频大赛
疫情对互联网科技公司影响
互联网金融科技平台
央行互联网金融科技公司
互联网时代科技改变生活
徐州市互联网科技有限公司
互联网第三次科技革命特征
四川互联网展示科技馆设计
吉林省码上互联网科技电话
现代互联网科技公司
科技互联网企业在行动