ORA-13364 Layer Dimensionality Does Not Match Geometry Dimensions (Doc ID 1594789.1)

Last updated on FEBRUARY 08, 2017

Applies to:

Oracle Spatial and Graph - Version 11.2.0.3 and later
Information in this document applies to any platform.

Symptoms

Trying to insert a geometry getting error:

ORA-13364: layer dimensionality does not match geometry dimensions

drop index "IDX_GEOMETRIA_BORRAR";
drop table BORRAR_EST_4326;
delete user_sdo_geom_metadata
where table_name = 'BORRAR_EST_4326';

CREATE TABLE "BORRAR_EST_4326"
  ( "OGR_FID" NUMBER(*,0),
  "ORA_GEOMETRY" "MDSYS"."SDO_GEOMETRY" );


INSERT INTO user_sdo_geom_metadata
  (TABLE_NAME,
  COLUMN_NAME,
  DIMINFO,
  SRID)
 VALUES (
 'BORRAR_EST_4326',--tabla
 'ORA_GEOMETRY',--campo
MDSYS.SDO_DIM_ARRAY(
MDSYS.SDO_DIM_ELEMENT('X',-5,7,1E-7),
MDSYS.SDO_DIM_ELEMENT('Y',36,46,1E-7),
MDSYS.SDO_DIM_ELEMENT('Z',-1000,10000,0.002)),
4326 -- SRID
);

select * from user_sdo_geom_metadata
where table_name = 'BORRAR_EST_4326';

CREATE INDEX "IDX_GEOMETRIA_BORRAR" ON "BORRAR_EST_4326" ("ORA_GEOMETRY")
  INDEXTYPE IS "MDSYS"."SPATIAL_INDEX" ;

insert into borrar_est_4326 (ora_geometry)
values (SDO_GEOMETRY(2001,4326,MDSYS.SDO_POINT_TYPE(0.524435165246,40.5589935551,24),NULL,NULL));

*
ERROR at line 1:
ORA-29875: failed in the execution of the ODCIINDEXINSERT routine
ORA-13364: layer dimensionality does not match geometry dimensions
ORA-06512: at "MDSYS.SDO_INDEX_METHOD_10I", line 720
ORA-06512: at "MDSYS.SDO_INDEX_METHOD_10I", line 225

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms