创建表产生死锁问题

juren250 2007-01-07 12:05:21
在执行以下语句时提示错误.
drop table test_a;
create table test_a tablespace tb_space storage(freelists 3) as select * from t_module_table where 1 = 2;

ORA-00604: error occurred at recursive SQL level 1
ORA-00060: deadlock detected while waiting for resource

此创建语句只有一个session处理,不存在多个同时处理的问题.t_module_table 是一个空表.按道理说应该不会出错。但产生的错误很奇怪.不知道有谁也遇到此类问题,还请指点一下。谢谢
...全文
185 7 打赏 收藏 转发到动态 举报
写回复
用AI写文章
7 条回复
切换为时间正序
请发表友善的回复…
发表回复
juren250 2007-01-08
  • 打赏
  • 举报
回复
揭帖
juren250 2007-01-08
  • 打赏
  • 举报
回复
揭帖
juren250 2007-01-08
  • 打赏
  • 举报
回复
小概率事件.只出现过一次,再也没有重现了.感谢各位的关注.
tgm78 2007-01-07
  • 打赏
  • 举报
回复
select b.sql_text text,a.sid sid ,a.serial# sria#,a.username username, c.type type,a.machine machine
from v$session a ,v$sqltext b ,v$access c
where c.object=upper('&1')
and c.type in ('TABLE','PACKAGE','PROCEDURE','FUNCTION','PACKAGE BODY')
and a.sid=c.sid
and b.address = a.sql_address
and b.hash_value = a.sql_hash_value
order by a.sid,a.serial#,b.piece;

按照提示输入表名字,看看是否有session在使用?
juren250 2007-01-07
  • 打赏
  • 举报
回复
回一楼的,test_a这个表确信当时是没有人使用的,只有我自己的session使用.
laoPB 2007-01-07
  • 打赏
  • 举报
回复
drop table test_a;
并没删除,需要提交,然后再create table ....
commit work;
tgm78 2007-01-07
  • 打赏
  • 举报
回复
ORA-00060: deadlock detected while waiting for resource
说明有人正在用这个表,所以你 不能drop,找出那个session在使用这个表,kill它即可drop

17,377

社区成员

发帖
与我相关
我的任务
社区描述
Oracle 基础和管理
社区管理员
  • 基础和管理社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

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