MySQL provides a number of functions that take as input parameters a
BLOB containing a Well-Known Binary representation
(and, optionally, a spatial reference
system identifier (SRID)), and return the corresponding geometry.
GeomFromWKT() accepts a WKB of any geometry type as its first
argument. An implementation also provides type-specific construction
functions for construction of geometry values of each geometry type.
GeomFromWKB(wkb[,srid])
GeometryFromWKB(wkt[,srid])
PointFromWKB(wkb[,srid])
POINT value using its WKB representation and SRID.
LineFromWKB(wkb[,srid])
LineStringFromWKB(wkb[,srid])
LINESTRING value using its WKB representation and SRID.
PolyFromWKB(wkb[,srid])
PolygonFromWKB(wkb[,srid])
POLYGON value using its WKB representation and SRID.
MPointFromWKB(wkb[,srid])
MultiPointFromWKB(wkb[,srid])
MULTIPOINT value using its WKB representation and SRID.
MLineFromWKB(wkb[,srid])
MultiLineStringFromWKB(wkb[,srid])
MULTILINESTRING value using its WKB representation and SRID.
MPolyFromWKB(wkb[,srid])
MultiPolygonFromWKB(wkb[,srid])
MULTIPOLYGON value using its WKB representation and SRID.
GeomCollFromWKB(wkb[,srid])
GeometryCollectionFromWKB(wkt[,srid])
GEOMETRYCOLLECTION value using its WKB representation and SRID.
The OpenGIS specification also describes optional functions for constructing
Polygon or MultiPolygon values based on the WKB representation
of a collection of rings or closed LineString values. These values
may intersect. MySQL does not yet implement these functions:
BdPolyFromWKB(wkb,srid)
Polygon value from a
MultiLineString value in WKB format containing
an arbitrary collection of closed LineString values.
BdMPolyFromWKB(wkb,srid)
MultiPolygon value from a
MultiLineString value in WKB format containing
an arbitrary collection of closed LineString values.