Wednesday, March 14, 2012

Upgrading ArcSDE 10 and ORA-00942

I got an Ora-00942 error. And the following link explains a good reason:

Problem:  Incorrect dbtune XML_IDX_INDEX_TEXT values cause ArcSDE for Oracle geodatabase upgrades to fail with "ORA-00942: table or view does not exist" (http://support.esri.com/en/knowledgebase/techarticles/detail/38312)


Description

If there is an invalid value for the XML_IDX_INDEX_TEXT parameter in the dbtune, upgrading an ArcSDE for Oracle geodatabase to version 10 fails with following error in the sde_setup.log:

"[....] Error creating GDB_Items table...
[....] ERROR Creating Geodatabase tables
, Error = -37
,EXT_Error = 942
,EXT_ERROR1 = ORA-00942: table or view does not exist"

Cause

This error occurs when trying to create new geodatabase schema tables with an incorrect value in the XML_IDX_INDEX_TEXT parameter of the DEFAULTS DBTUNE keyword similar to the following:

"TABLESPACE TEST"

▪ The value of this parameter can be checked using the following ArcSDE admin command:

sdedbtune -o list -u sde -p sde -i sde:oracle10g:test -k DEFAULTS -P XML_IDX_INDEX_TEXT

ArcSDE 10.0 for Oracle11g Build 685 Fri May 14 12:05:43 2010
Attribute Administration Utility
-----------------------------------------------------
##DEFAULTS

XML_IDX_INDEX_TEXT "TABLESPACE TEST"

END

▪ The following is the actual SQL that fails:

SQL> CREATE INDEX xmldocix5_tx ON sde_xml_doc5 (xml_doc_val) INDEXTYPE IS CTXSYS.CONTEXT PARAMETERS('TABLESPACE TEST');

CREATE INDEX xmldocix5_tx ON sde_xml_doc5 (xml_doc_val) INDEXTYPE IS CTXSYS.CONTEXT PARAMETERS('TABLESPACE TEST')
*
ERROR at line 1:
ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
ORA-20000: Oracle Text error:
DRG-11000: invalid keyword TABLESPACE
ORA-06512: at "CTXSYS.DRUE", line 160
ORA-06512: at "CTXSYS.TEXTINDEXMETHODS", line 364

Solution or Workaround

  1. Remove the config_string for the XML_IDX_INDEX_TEXT parameter in the DEFAULTS keyword from the DBTUNE.

    OR

    Make sure its value is valid for Oracle text. See the Oracle documentation for more information - there is a link to the Oracle documentation in the Related Information section below.
  2. Re-run the geodatabase upgrade.


More Oracle DBA tips, please visit Oracle DBA Tips 

No comments:

Post a Comment