我试图对现有表进行分区,而不使用Oracle删除和重新创建它。
我的Oracle10g支持应用程序中的DBMS_REDEFINITION包
我已经给予用户所有必要的许可,如甲骨文中所提到的。
grant CREATE ANY TABLE to DDUSER;
grant ALTER ANY TABLE to DDUSER;
grant DROP ANY TABLE to DDUSER;
grant LOCK ANY TABLE to DDUSER;
grant SELECT ANY TABLE to DDUSER;
grant execute on dbms_redefinition to DDUSER;我可以执行以下程序
begin
Dbms_Redefinition.Can_Redef_Table('DDUSER', 'TABLE');
end;
This throws no error neither any result (Assuming this is as expected)但当我试图逃跑时
BEGIN
DBMS_REDEFINITION.start_redef_table(
uname => 'DDUSER',
orig_table => 'TABLE',
int_table => 'TABLE_1');
END;我正在犯以下错误:
错误报告: ORA-01031:特权不足 ORA-06512:在"SYS.DBMS_REDEFINITION",第50行 ORA-06512:"SYS.DBMS_REDEFINITION",第1343行 ORA-06512:在第2行 01031。00000 -“特权不足”
你能帮帮我吗,我在这里失去了什么特权?或者是否知道在package DBMS_REDEFINITION第50行中执行哪一项操作?
发布于 2014-05-22 13:49:20
试试这个:
grant DROP ANY INDEX to DDUSER;
grant CREATE ANY INDEX to DDUSER;如果表格包含一个索引(很可能是这样的),那么您必须创建新的索引。
发布于 2018-07-15 05:45:49
我刚面对这个问题。我在start_redef_table上也得到了同样的错误。
因此,在搜索了很多之后,我给了用户以下特权,并且它起了作用。
grant execute on dbms_redefinition package to myuser (你已经有了)
然后
grant CREATE ANY TABLE to myuser;
grant ALTER ANY TABLE to myuser;
grant DROP ANY TABLE to myuser;
grant LOCK ANY TABLE to myuser;
grant SELECT ANY TABLE to myuser;在授予这些特权之后,start_redef_table运行得非常完美。
发布于 2018-02-20 10:29:44
在Oracle 12c上有额外的系统特权“重新定义任何表”。
这对我有用。
grant REDEFINE ANY TABLE to myUser;
grant ADMINISTER DATABASE TRIGGER to myUser;
grant ALTER ANY INDEX to myUser;
grant ALTER ANY MATERIALIZED VIEW to myUser;
grant ALTER ANY SEQUENCE to myUser;
grant ALTER ANY TRIGGER to myUser;
grant CREATE ANY INDEX to myUser;
grant CREATE ANY MATERIALIZED VIEW to myUser;
grant CREATE ANY SEQUENCE to myUser;
grant CREATE ANY TABLE to myUser;
grant CREATE ANY TRIGGER to myUser;
grant CREATE ANY VIEW to myUser;
grant CREATE MATERIALIZED VIEW to myUser;
grant CREATE SESSION to myUser;
grant CREATE VIEW to myUser;
grant DROP ANY INDEX to myUser;
grant DROP ANY MATERIALIZED VIEW to myUser;
grant DROP ANY SEQUENCE to myUser;
grant DROP ANY TRIGGER to myUser;
grant DROP ANY VIEW to myUser;
grant EXECUTE ANY PROCEDURE to myUser;
grant INSERT ANY TABLE to myUser;
grant MERGE ANY VIEW to myUser;
grant SELECT ANY DICTIONARY to myUser;
grant SELECT ANY TABLE to myUser;
grant UNDER ANY VIEW to myUser;
grant UPDATE ANY TABLE to myUser;祝好运
https://stackoverflow.com/questions/23805521
复制相似问题