删除type报ORA-02303错误

 drop type result_type 时,
报错ORA-02303: 无法使用类型或表的相关性来删除或取代一个类型
 drop  type result_type_array 时
报错  对象不存在

CREATE OR REPLACE TYPE "result_type"   as object
(
Seg_node    VARCHAR2(20),  
Seg_name    VARCHAR2(200),   
Seg_code    VARCHAR2(20)
)

CREATE OR REPLACE TYPE "result_type_array"   as table of "result_type";

原因:没有大写和双引号的问题,如果没有大写
解决方法:drop  type "result_type_array"
          drop  type "result_type_array"

在不删除使用type表的相关表的情况下,强制删除type,这样相关表里的对应type的列也被删除

drop type t_air force

 

如果不使用双引号,会默认为大写,使用双引号就是双引号内的名称。


上网查找的原因:
ORA-02303        cannot drop or replace a type with type or table dependent(s)

Cause        An attempt was made to drop or replace a type that has dependents.
Action        Drop all type(s) and table(s) depending on the type, then retry the operation or use the FORCE option.

Copyright (C) 1998, Oracle Corporation

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/14613712/viewspace-616667/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/14613712/viewspace-616667/

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值