Skip to Main Content

Database Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to use SDO_GEOM.WITHIN_DISTANCE with a geodetic CRS and degree as unit?

772241May 19 2010 — edited May 20 2010
Hi,

I am trying to use SDO_GEOM.WITHIN_DISTANCE on geodetic data, but I don't want to use meter as unit for the tolerance. I thought I simply can set the unit to 'Degree', but this does not work:

select SDO_GEOM.WITHIN_DISTANCE(
MDSYS.SDO_GEOMETRY('POINT(0 0)', 4326),
+11,+
MDSYS.SDO_GEOMETRY('POINT(0 10)', 4326),
+0.00000000005,+
+'unit=Degree') from dual;+

ORA-13291: conversion error between the specified unit and standard unit
ORA-06512: at "MDSYS.SDO_3GL", line 985
ORA-06512: at "MDSYS.SDO_GEOM", line 1034
ORA-06512: at "MDSYS.SDO_GEOM", line 1049
ORA-06512: at line 1
+13291. 00000 - "conversion error between the specified unit and standard unit"+
*Cause: Cannot convert the specified unit from/to standard unit+
for linear distance, angle, or area.
*Action: Check the unit specification and respecify it.+

What am I doing wrong?

Update: How is the specified unit used? Is WITHIN_DISTANCE trying to convert my 10 degree into a meter value? Because then I would understand why it is not working.

Thanks,
Tobias

Edited by: tsauerwein on May 19, 2010 11:23 PM
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 17 2010
Added on May 19 2010
2 comments
1,608 views