ST_AsBinary
Signatures
BINARY ST_AsBinary(GEOMETRY geom);
Description
Converts geom
into its Well Known Binary value.
Implements the OpenGIS Simple Features Implementation Specification for SQL version 1.2.1.
Example
SELECT ST_AsBinary(
ST_GeomFromText('POLYGON((0 0, 0 1, 1 1, 1 0, 0 0))', 4326));
-- Answer: 0020000003000010e600000001000000050000000000000000
-- 000000000000000000000000000000003ff00000000000003ff0000
-- 0000000003ff00000000000003ff000000000000000000000000000
-- 0000000000000000000000000000000000