[Mapserver-users] Oracle Spatial Extents
Vladimir Guzmán
bigfoot at main-task.com
Fri Jul 23 18:56:15 PDT 2004
Hello.
I need to get the extents of a geometry in Oracle Spatial.
I'm using the following query:
MIN(SDO_GEOM.SDO_MIN_MBR_ORDINATE(GEOMETRY_TABLE.ORA_GEOMETRY,
m.diminfo,1)) as XMIN,
MIN(SDO_GEOM.SDO_MIN_MBR_ORDINATE(GEOMETRY_TABLE.ORA_GEOMETRY,
m.diminfo,2)) as YMIN,
MAX(SDO_GEOM.SDO_MAX_MBR_ORDINATE(GEOMETRY_TABLE.ORA_GEOMETRY,
m.diminfo,1)) as XMAX,
MAX(SDO_GEOM.SDO_MAX_MBR_ORDINATE(GEOMETRY_TABLE.ORA_GEOMETRY,
m.diminfo,2)) as YMAX
FROM GEOMETRY_TABLE, user_sdo_geom_metadata m
WHERE m.table_name = 'GEOMETRY_TABLE' AND m.column_name = 'ORA_GEOMETRY';
But Oracle takes 29 seconds (!) to get the extents.
Is this a normal behavior?
The geometry is indexed using:
CREATE INDEX GEOMETRY_TABLE_SPATIAL_IDX
ON GEOMETRY_TABLE(ORA_GEOMETRY)
INDEXTYPE IS MDSYS.SPATIAL_INDEX;
The geometry has ~2500 records.
The geometry's SRID is 1 (Sinusoidal WGS84).
Am I using the wrong query?
Is there another way?
Anyone has experienced a related problem?
Thanks in advance for your help.
--
Vladimir Ilich Guzmán R.
------------------------
http://maintask.com
More information about the MapServer-users
mailing list