I have a table which contains an field zoneShape
of the type Polygon
.
When inserting some geometry in this field, in phpmyadmin it says: affected 1 row. The row is added, but the geometry field says it's size is 0B. Which can't be accurate, cause it has multiple points.
This is the Insertion code:
SET @g = 'POLYGON(50.866753 5.686455, 50.859819 5.708942, 50.851475 5.722675, 50.841611 5.720615, 50.834023 5.708427, 50.840744 5.689373, 50.858735 5.673923, 50.866753 5.686455)';
INSERT INTO zone SET zoneShape = PolygonFromText(@g)
As you can see; the first and last point are the same, so the polygon is closed.
Can anyone help me with adding this polygon to the database?