oracle ORA-00054 删除表时资源繁忙
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/5089319/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
ORA-00054 Resource busy when dropping table
提问by Avi
Can somebody explain this error?
有人可以解释这个错误吗?
ORA-00054: Resource busy and aquire with NOWAIT specified
ORA-00054: 资源繁忙并使用指定的 NOWAIT 获取
This error came in a DROP TABLE
. Because of it, procedures and packages are not getting compiled.
此错误出现在DROP TABLE
. 因此,程序和包没有被编译。
回答by APC
ORA-00054
means some other session has a lock on a database object which prevents our action from completely successfully.
ORA-00054
意味着其他一些会话锁定了一个数据库对象,这会阻止我们的操作完全成功。
Your scenario as you present it is a trifle confused, but basically somebody has a lock on the table - probably they are xecuting some DML against it - and you won't be able to drop it until they release that lock (i.e. commit or rollback).
您呈现的场景有点令人困惑,但基本上有人锁定了表 - 可能他们正在针对它执行一些 DML - 并且在他们释放该锁定之前您将无法删除它(即提交或回滚)。
Having said all which I'm not sure why you'd want to drop a table to fix a PL/SQL compilation problem. You should revise your question to give us a clearer picture of what you're trying to achieve.
说了这么多,我不确定您为什么要删除一个表来修复 PL/SQL 编译问题。你应该修改你的问题,让我们更清楚地了解你想要实现的目标。
回答by Burhan
you may have a query or a job running against the table. your objects cannot be recompiled or dropped until that long running queries/jobs are finished. Alternatively, you can kill any sessions except yours and then proceed with the compilation.
您可能有针对该表运行的查询或作业。在长时间运行的查询/作业完成之前,您的对象无法重新编译或删除。或者,您可以终止除您的会话之外的任何会话,然后继续编译。