35.5 SDO_UTIL.CONCAT_LINES
Format
SDO_UTIL.CONCAT_LINES( geometry1 IN SDO_GEOMETRY, geometry2 IN SDO_GEOMETRY ) RETURN SDO_GEOMETRY;
Description
Concatenates two line or multiline two-dimensional geometries to create a new geometry.
Parameters
Usage Notes
Each input geometry must be a two-dimensional line or multiline geometry (that is, the SDO_GTYPE value must be 2002 or 2006). This function is not supported for LRS geometries. To concatenate LRS geometric segments, use the SDO_LRS.CONCATENATE_GEOM_SEGMENTS function (described in SDO_LRS Package (Linear Referencing System) ).
The input geometries must be line strings whose vertices are connected by straight line segments. Circular arcs and compound line strings are not supported.
If an input geometry is a multiline geometry, the elements of the geometry must be disjoint. If they are not disjoint, this function may return incorrect results.
The topological relationship between geometry1
and geometry2
must be DISJOINT or TOUCH; and if the relationship is TOUCH, the geometries must intersect only at two end points.
You can use the SDO_AGGR_CONCAT_LINES spatial aggregate function (described in Spatial Aggregate Functions) to concatenate multiple two-dimensional line or multiline geometries.
An exception is raised if geometry1
and geometry2
are based on different coordinate systems.
Examples
The following example concatenates two simple line string geometries.
-- Concatenate two touching lines: one from (1,1) to (5,1) and the -- other from (5,1) to (8,1). SELECT SDO_UTIL.CONCAT_LINES( SDO_GEOMETRY(2002, NULL, NULL, SDO_ELEM_INFO_ARRAY(1,2,1), SDO_ORDINATE_ARRAY(1,1, 5,1)), SDO_GEOMETRY(2002, NULL, NULL, SDO_ELEM_INFO_ARRAY(1,2,1), SDO_ORDINATE_ARRAY(5,1, 8,1)) ) FROM DUAL; SDO_UTIL.CONCAT_LINES(SDO_GEOMETRY(2002,NULL,NULL,SDO_ELEM_INFO_ARRAY(1,2,1),SDO -------------------------------------------------------------------------------- SDO_GEOMETRY(2002, NULL, NULL, SDO_ELEM_INFO_ARRAY(1, 2, 1), SDO_ORDINATE_ARRAY( 1, 1, 5, 1, 8, 1))
Parent topic: SDO_UTIL Package (Utility)