Arc Catalog重建索引时报错:ORA-02298: 无法验证 (SDE.A18_FK1) - 未找到父项关键字 (A18_FK1)
Arc Catalog重建索引时报错:
---------------------------
Error---------------------------
Failed to add spatial index.
Underlying DBMS error[ORA-02298: 无法验证 (SDE.A18_FK1) - 未找到父项关键字
(A18_FK1)]
The specified feature dataset extension type was not found.
这个错是由图层上的B表的shape字段在F表里没找到,处理:
delete XXXX(图层字段) t where not exists(select 1 from FAAA t2 where t2.fid=t.shape)
其中FAAA为F18 (根据外键约束A18_FK1得到)
如果报:
ORA-XX,键不唯一(忘了ORA错误号了)
则是因为图层B表里有重复的ObjectId记录.
处理:删除导致重复的记录,如:
create table cstmp.jj_p_lcfh_annotationDupShape as select shape,count(*) CNT from jj_p_lcfh_annotation t group by shape having count(*) >1
delete jj_p_lcfh_annotation t1 where exists(select 1 from cstmp.jj_p_lcfh_annotationDupShape t2 where t2.shape=t1.shape) and t1.objectid in (select max(t3.objectid) from jj_p_lcfh_annotation t3 where t3.shape=t1.shape)
这些问题出现的原因还未知,使用Arcgis 9.2连Arc SDE 9.0.