ArcMap cannot create layer cases in Oracle

Keywords: SQL Oracle

Recently, colleagues used ArcMap to create layers in the customer's site, so simply record the process.

The software version environment is:

ArcGIS Desktop 10.2.1

Oracle 11.2.0.4

For reasons of confidentiality, error screenshots cannot be provided, only error codes can be provided.

The error code is ora-29881

[oracle@bigdataserver ~]$ oerr ora 29881
29881, 00000, "failed to validate indextype"
// *Cause: Indextype cannot be compiled.
// *Action : Try to compile the indextype which is referenced by
//           the domain index.

It's an indextype problem, so the first thought is to create a spatial index after creating a layer. The spatial index is a domain index, and its indextype is st_spatial_index.

It is recommended that it be recompiled first:

SQL> alter indextype st_spatial_index compile;

Indextype altered.

After normal recompilation, colleague feedback problems still exist.

So the problem is not with this indextype, but with other indextypes. It is suggested that colleagues query invalid objects under users.

SQL> select object_name,object_type from user_objects where status='INVALID';

Colleague feedback returned four records, respectively:

XMLDOCIX4_TX
XMLDOCIX3_TX
XMLDOCIX2_TX
XMLDOCIX1_TX

And all types are indexed.

Then let colleagues use alter index xmldocix1_ix rebuild; the result of rebuild index is also reported ora-29881. So far the problem has been found, which is caused by the four indexes.

Continue to look at the definitions of these four indexes:

SQL> select dbms_metadata.get_ddl('INDEX','XMLDOCIX1_TX','SDE') from dual;

DBMS_METADATA.GET_DDL('INDEX','XMLDOCIX1_TX','SDE')
--------------------------------------------------------------------------------

  CREATE INDEX "SDE"."XMLDOCIX1_TX" ON "SDE"."SDE_XML_DOC1" ("XML_DOC_VAL")
   INDEXTYPE IS "CTXSYS"."CONTEXT"

SQL> select dbms_metadata.get_ddl('INDEX','XMLDOCIX2_TX','SDE') from dual;

DBMS_METADATA.GET_DDL('INDEX','XMLDOCIX2_TX','SDE')
--------------------------------------------------------------------------------

  CREATE INDEX "SDE"."XMLDOCIX2_TX" ON "SDE"."SDE_XML_DOC2" ("XML_DOC_VAL")
   INDEXTYPE IS "CTXSYS"."CONTEXT"

SQL> select dbms_metadata.get_ddl('INDEX','XMLDOCIX3_TX','SDE') from dual;

DBMS_METADATA.GET_DDL('INDEX','XMLDOCIX3_TX','SDE')
--------------------------------------------------------------------------------

  CREATE INDEX "SDE"."XMLDOCIX3_TX" ON "SDE"."SDE_XML_DOC3" ("XML_DOC_VAL")
   INDEXTYPE IS "CTXSYS"."CONTEXT"

SQL> select dbms_metadata.get_ddl('INDEX','XMLDOCIX4_TX','SDE') from dual;

DBMS_METADATA.GET_DDL('INDEX','XMLDOCIX4_TX','SDE')
--------------------------------------------------------------------------------

  CREATE INDEX "SDE"."XMLDOCIX4_TX" ON "SDE"."SDE_XML_DOC4" ("XML_DOC_VAL")
   INDEXTYPE IS "CTXSYS"."CONTEXT"

These four indexes are also domain indexes, which are used for full-text retrieval.

Continue to let colleagues see if CONTEXT is normal.

SQL> select  status from all_objects where owner='CTXSYS' and object_type='INDEXTYPE' and object_name='CONTEXT';

STATUS
-------
VALID

The result of colleague feedback is VALID, which is the problem of CONTEXT itself, that is, the index itself is invalid for unknown reasons. It is suggested that colleagues delete the four indexes and rebuild them.

The problem of reconstruction was solved after deletion.

Posted by st0rmer on Sun, 21 Apr 2019 21:09:34 -0700