`

ORA-02449错误

阅读更多
ERROR at line 1:
ORA-02449: unique/primary keys in table referenced by foreign keys.
Oracle官网上的解释:
Cause: An attempt was made to drop a table with unique or primary keys referenced by foreign keys in another table.
Action: Before performing the above operations the table, drop the foreign key constraints in other tables. You can see what constraints are referencing a table by issuing the following command: SELECT * FROM USER_CONSTRAINTS WHERE TABLE_NAME = "tabnam";
造成的原因是:因为当前产生错误的表中的字段被其它表作为外键使用。
解决方法:
如果要考虑外键的约束关系,则需要找出哪些表引用了被删除表的主键或者惟一键,然后删除掉这些约束,再删除表。
0
0
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics