English

Error: GSE1052E An SQL error occurred when the spatial extender tried to create spatial index

Error Message

ArcSDE for DB2 allows you to calculate a layer with an invalid spatial index. The following error may occur:

"GSE1052E An SQL error occurred when the spatial extender tried to create spatial index..."

Cause

If you use 'sdelayer -o alter' to alter a feature class' spatial index grid size to an invalid grid size, then put the layer into load_only_io, you can't put it back into normal_io, even if you reset the the grid size to a correct size.

Note: DO NOT ATTEMPT THIS IF YOU HAVE A LAYER THAT IS CORRECTLY IN NORMAL_IO. Only attempt this with a layer experiencing this problem.

To reproduce:
1. Calculate an invalid grid size on a feature class

2. Put the layer into load_only_io using sdelayer -o load_only_io

3. Try to put the layer into normal io. You should get an error like this:

"GSE1052E An SQL error occurred when the spatial extender tried to create spatial index..."

4. Change the grid size using sdelayer -o alter. Calculate the grid size to a valid grid.

5. Try to put the layer into normal_io. You'll get this error:

ArcSDE 8.1 Build 363 Mon Mar 26 09:51:07 PST 2001
Layer Administration Utility
-----------------------------------------------------
Error: Underlying DBMS error (-51).
Error: Setting Layer to NORMAL I/O mode.
[IBM][CLI Driver][DB2/6000] SQL0601N The name of the object to be created is id
entical to the existing name "VTEST.SC_UPD_CASC_12" of type "TRIGGER". SQLSTATE
=42710

42710
Layer is still in LOAD-ONLY mode!

Solution or Workaround

Drop the trigger listed in the error using DB2 Enterprise manager or SQL with the DB2 command line utility.

Change the grid size using 'sdelayer -o alter' and use a valid grid size.

Set the layer back to normal I/O mode using 'sdelayer -o normal_io'.