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!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

JSON to SDO_GEOMETRY: ORA-13050: unable to construct spatial object

User_1871May 11 2022 — edited May 12 2022

Oracle 21c:
I have a JSON polyline:

{
"spatialdimension" : 2,
"line" : {"datapoints" : [[1,2,0],[3,4,2.82]]}
}

I want to convert that JSON to SDO_GEOMETRY:

select
  SDO_UTIL.FROM_GEOJSON('{ "spatialdimension" : 2, "line" : {"datapoints" : [[1,2,0],[3,4,2.82]]}}')
from
  dual

https://dbfiddle.uk/?rdbms=oracle_21&fiddle=287ebaddbad6021d160140b3d5e2ece6

I get an error: ORA-13050: unable to construct spatial object
What am I doing wrong? Thanks.

This post has been answered by _jum on May 12 2022
Jump to Answer

Comments

Post Details

Added on May 11 2022
1 comment
334 views