Bug #54065 Support OGC standard WKT for MULTIPOINT
Submitted: 28 May 2010 12:55 Modified: 1 Oct 2015 15:52
Reporter: Michael Frhler Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: GIS Severity:S4 (Feature request)
Version:4.1, 5.0, 5.1, 5.6.99 OS:Any
Assigned to: CPU Architecture:Any

[28 May 2010 12:55] Michael Frhler
Description:
When I use the MultiPointFromText function in a MySQL insert statement everything works fine when I use the following WKT:

MULTIPOINT (8 9 , 4 5)

when I use the following WKT (which is also OGC conform):

MULTIPOINT ((8 9), (4 5))

In my geometry column no geometry but "NULL" is inserted. I get no error message!!!

How to repeat:
drop table if exists testmpoint;
create table testmpoint(
id int,
geom MultiPoint);

insert into testmpoint(id,geom) values (1,MultiPointFromText("MULTIPOINT (8 9 , 4 5)"));
insert into testmpoint(id,geom) values (2,MultiPointFromText("MULTIPOINT ((8 9) , (4 5))"));

commit;

Suggested fix:
Support braces in MultiPoint WKT
[29 May 2010 6:39] Sveta Smirnova
Thank you for the report.

Verfieid as described. No warning even issued.
[8 May 2015 11:53] Norvald Ryeng
Posted by developer:
 
MySQL 5.7 (I tried 5.7.7) rejects the second syntax with an error message.

You are right, the OGC WKT spec requires an extra set of parenthesis. Examples in the SQL/MM standard don't use them.

I'm changing the status of this bug to a feature request to support OGC WKT syntax, i.e., "MULTIPOINT((0 0), (1 1))" in addition to "MULTIPOINT(0 0, 1 1)".
[1 Oct 2015 15:52] Paul DuBois
Noted in 5.7.9, 5.8.0 changelogs.

Spatial functions such as ST_MPointFromText() and ST_GeomFromText()
that accept WKT-format representations of MultiPoint values now
permit individual points within values to be surrounded by
parentheses. For example, both of the following function calls are
valid, whereas previously the second one produced an error:

ST_MPointFromText('MULTIPOINT (1 1, 2 2, 3 3)')
ST_MPointFromText('MULTIPOINT ((1 1), (2 2), (3 3))')

In addition, functions such as ST_AsText() and ST_AsWKT() that
produce WKT-format results now display MultiPoint values with
parentheses surrounding each point.