Class SpatialUnion
- Namespace
- YndigoBlue.Velocity.Functions
- Assembly
- YndigoBlue.Velocity.dll
Represents the ST_Union spatial analysis function that computes the spatial union of two geometries.
public class SpatialUnion : Function, IElement, ICheckItem, IDefaultItem, IFilterItem
- Inheritance
-
SpatialUnion
- Implements
Remarks
Warning
Spatial functions are not available in the Community Edition of Velocity. They require the Full Edition.
The ST_Union function returns a geometry representing the point set union of two spatial objects (the set of points that are in either geometry). The result combines both geometries, merging overlapping areas and dissolving internal boundaries. Useful for combining adjacent parcels, merging service areas, or creating aggregate geographic regions. The output geometry type depends on the inputs and their spatial relationship. OGC-compliant.
Return Types by Relationship:
| Relationship | Union Result |
|---|---|
| Overlapping polygons | POLYGON (merged, no internal boundary) |
| Adjacent polygons | POLYGON (merged along shared edge) |
| Disjoint polygons | MULTIPOLYGON (both separate) |
| Disjoint points | MULTIPOINT |
| B inside A | A (B absorbed) |
Example Results: ST_Union(PY0, X)
| Shape X | Union Result |
|---|---|
| PY1 (inside PY0) | PY0 - PY1 absorbed |
| PY2 (outside PY0) | MULTIPOLYGON(PY0, PY2) |
| PY3 (touches PY0) | POLYGON - merged at touch point |
| PY4 (overlaps PY0) | POLYGON - merged into single shape |
| PT1 (inside PY0) | PY0 - point absorbed |
| PT2 (outside PY0) | GEOMETRYCOLLECTION(PY0, PT2) |
Constructors
- SpatialUnion(Geometry, Column)
Initializes a new instance of ST_Union with a geometry literal and column.
- SpatialUnion(Geometry, Function)
Initializes a new instance of ST_Union with a Geometry literal and function result for function chaining.
- SpatialUnion(Column, Geometry)
Initializes a new instance of ST_Union with a column and geometry literal.
- SpatialUnion(Column, Column)
Initializes a new instance of ST_Union with two columns for spatial joins.
- SpatialUnion(Column, Function)
Initializes a new instance of ST_Union with a column and function result for function chaining.
- SpatialUnion(Column, Geography)
Initializes a new instance of ST_Union with a column and geography literal.
- SpatialUnion(Function, Geometry)
Initializes a new instance of ST_Union with a function result and Geometry literal for function chaining.
- SpatialUnion(Function, Column)
Initializes a new instance of ST_Union with a function result and column for function chaining.
- SpatialUnion(Function, Function)
Initializes a new instance of ST_Union with two function results for function chaining.
- SpatialUnion(Function, Geography)
Initializes a new instance of ST_Union with a function result and Geography literal for function chaining.
- SpatialUnion(Geography, Column)
Initializes a new instance of ST_Union with a geography literal and column.
- SpatialUnion(Geography, Function)
Initializes a new instance of ST_Union with a Geography literal and function result for function chaining.