Can't store modified polygon with holes in Oracle Spatial

Hi there,

 I'm trying access Oracle Spatial data of gtype 2003 (polygon). I've setup a small Bwentley Map schema and registered the table as xfm feature. Readout of feature works well, polygons and polygons with holes show up nicely in dgn. Modifying the polygons by adding or deleting hole polygons works as expected in the dgn.

But when it comes to comitting the data back to Oracle Spatial I'm getting an error in message center

ORA-13199: the given geometry cannot be rectified

ORA-06512 : at "MDSYS.MD", ...

ORA-06512 : at "MDSYS.MDERR", ...

ORA-06512 : at "MDSYS.SDO_UTIL", ...


This is odd, because the polygon and its inner boundary are simple squares.

Is there a way to log the geometry that Bentley Map tries to rectify, the v$sql view in Oracle does not show ADT parameter values.

MicroStation 08.11.09.459
BMap 08.11.09.107

Regards,
Holger

Parents
  • Most generally the rectify geometry does the following checks of the entity :
     

    ·         Duplicate vertices

    ·         Polygon boundary intersecting itself

    ·         Incorrect orientation of exterior or interior rings (or both) of a polygon

     
    I know from past experience that it is sometimes very easy to duplicate vertices(points) in a polygon, especially if I am doing modifications to the polygon ( insert vertexes, delete vertexes). This occurs even if the vertexes are not exactly the same but fit within the tolerance defined for the spatial layer.
     
    The polygon boundary intersecting itself is readily visible, so that probably is not the issue here. You would be able to see this visually, so it is not hidden from you.
     
    The last item, incorrect orientation, Bentley Map should be taking care of, even if you drew the polygon in the reverse order ( based upon if it is a interior/exterior ring).
     
    So I would check the duplicate vertexes first to see if that may be causing the problem.
     
    Jerry Walter
    Geospatial Advisor
    Mapping - US and Canada
    +1 937 205 3674 (office)
    +1 937 205 3674 (mobile)
    Skype : jerry.walter.troy
     
     

     

Reply
  • Most generally the rectify geometry does the following checks of the entity :
     

    ·         Duplicate vertices

    ·         Polygon boundary intersecting itself

    ·         Incorrect orientation of exterior or interior rings (or both) of a polygon

     
    I know from past experience that it is sometimes very easy to duplicate vertices(points) in a polygon, especially if I am doing modifications to the polygon ( insert vertexes, delete vertexes). This occurs even if the vertexes are not exactly the same but fit within the tolerance defined for the spatial layer.
     
    The polygon boundary intersecting itself is readily visible, so that probably is not the issue here. You would be able to see this visually, so it is not hidden from you.
     
    The last item, incorrect orientation, Bentley Map should be taking care of, even if you drew the polygon in the reverse order ( based upon if it is a interior/exterior ring).
     
    So I would check the duplicate vertexes first to see if that may be causing the problem.
     
    Jerry Walter
    Geospatial Advisor
    Mapping - US and Canada
    +1 937 205 3674 (office)
    +1 937 205 3674 (mobile)
    Skype : jerry.walter.troy
     
     

     

Children
  • I checked and found no errors.

    So I created a little test geometry in Oracle and tried to modify it within BM. 

    INSERT INTO buildings VALUES(

     5,

     SDO_GEOMETRY(

       2003,  -- two-dimensional polygon

       31467,

       NULL,

       SDO_ELEM_INFO_ARRAY(1,1003,3, 5, 2003, 3),

       SDO_ORDINATE_ARRAY(3400100,5300100, 3400200,5300200, 3400120, 5300120, 3400180, 5300180)

     ),

     'House 5'

    );

    I moved the feature for 10 meters and tried to commit. Same result ! Needless to say the geometry validated fine in Oracle.

    Is there a way to see what is exactly sent to the database. I can see it does "select sdo_util.rectify_geometry(:1, :2) from dual", but what geometry does BM send ?

    Holger