Format
SDO_GEOM.SDO_SELF_UNION( geom1 IN SDO_GEOMETRY, dim1 IN SDO_DIM_ARRAY, ) RETURN SDO_GEOMETRY;
or
SDO_GEOM.SDO_SELF_UNION( geom1 IN SDO_GEOMETRY, tol IN NUMBER ) RETURN SDO_GEOMETRY;
Description
Returns a valid geometry object that is the topological self union of one geometry object, which can be invalid.
Parameters
Geometry object.
Dimensional information array corresponding to geom1
, usually selected from one of the xxx_SDO_GEOM_METADATA views (described in Geometry Metadata Views).
Tolerance value (see Tolerance).
Usage Notes
This function can be used to fix the following problems that can make a geometry invalid:
Polygon boundary intersecting itself
Incorrect orientation of exterior or interior rings (or both) of a polygon
Examples
The following example returns a valid geometry object that is the topological self union of an invalid polygon.
-- Return the topological self union of an invalid geometry. SELECT SDO_GEOM.SDO_SELF_UNION( SDO_GEOMETRY(2003, NULL, NULL, SDO_ELEM_INFO_ARRAY(1, 1003, 1), SDO_ORDINATE_ARRAY(1, 1, 1, 4, 4, 4, 4, 1, 1, 1)), 0.00005) FROM dual; SDO_GEOM.SDO_SELF_UNION(SDO_GEOMETRY(2003,NULL,NULL,SDO_ELEM_INFO_ARRAY(1,1003,1 -------------------------------------------------------------------------------- SDO_GEOMETRY(2003, NULL, NULL, SDO_ELEM_INFO_ARRAY(1, 1003, 1), SDO_ORDINATE_ARRAY(1, 4, 1, 1, 4, 1, 4, 4, 1, 4))