ToGeoJSON - spectrum_spatial - Latest

Spectrum Spatial Guide

Product type
Software
Portfolio
Locate
Product family
Spectrumâ„¢ software
Product
Spectrumâ„¢ software > Spatial > Spectrum Spatial
Version
Latest
ft:locale
en-US
Product name
Spectrum Technology Platform
ft:title
Spectrum Spatial Guide
Copyright
2025
First publish date
2007
ft:lastEdition
2025-03-07
ft:lastPublication
2025-03-07T10:28:48.112000

Description

Converts a Spatial Geometry to its GeoJSON (geospatial data interchange format based on JavaScript Object Notation (JSON)) equivalent. This function converts feature geometry into the corresponding following GeoJSON geometry types: Point, LineString, Polygon, MultiPoint, MultiLineString, MultiPolygon, and GeometryCollection. The GeoJSON specification follows the defined JSON from http://geojson.org/geojson-spec.html.

Syntax

ToGeoJSON (obj )

Arguments

obj is a Spatial Feature geometry

Example

Returns a GeoJSON string from a feature geometry.

select ToGeoJSON(obj) from "/Samples/NamedTables/WorldTable" where country='Madagascar'