ST_GeomFromSDE
Converts a geometry object from ESRI Compressed Binary (SDE) format.
ST_GeomFromSDE is exactly the same as ST_SDEToSQL, and is the reverse of ST_AsSdeBinary.
Syntax
ST_GeomFromSDE(geo, srid);
- geo
- The input geometry, in SDE format.
Type: VARBINARY(ANY)
- srid
- The spatial reference system (SRS) identifier of the input geometry.
Type: VARCHAR(ANY)
Returns
A value of type ST_GEOMETRY(ANY) that contains the converted geometry.
Examples
SELECT inza..ST_AsText(inza..ST_GeomFromSDE(inza..ST_AsSdeBinary(inza..ST_WKTToSQL('POLYGON ((0 0, 11 0, 11 11, 0 11, 0 0))')), 4326));
ST_ASTEXT
-----------
POLYGON ((0 0, 11 0, 11 11, 0 11, 0 0))
(1 row)
SELECT inza..ST_AsText(inza..ST_GeomFromSDE(inza..ST_AsSdeBinary(inza..ST_WKTToSQL('LINESTRING(0 0, 3 4, -1 1)')), 4326));
ST_ASTEXT
-----------
LINESTRING (0 0, 3 4, -1 1)
(1 row)
SELECT inza..ST_AsText(inza..ST_GeomFromSDE(inza..ST_AsSdeBinary(inza..ST_Point(1, 5)), 4326));
ST_ASTEXT
-----------
POINT (1 5)
(1 row)