tile38 icon indicating copy to clipboard operation
tile38 copied to clipboard

Error invalid coordinates when set a new object

Open ghost opened this issue 5 years ago • 2 comments

Hi, I used this command to add new object of type polygon. I think the coordinates are correctly but somehow it returns error invalid coordinates.

http://localhost:9851/SET test thisIsTest OBJECT {"type":"Polygon","coordinates":[[[7.446993, 51.510959],[7.450195, 51.511600],[7.450066, 51.507620],[7.446867, 51.508127]]]}

Is the following command correctly?

SET keyID fieldName OBJECT {"type":"Polygon","coordinates":[[[longitude, latitude],[longitude, latitude],[longitude, latitude],[longitude, latitude]]]}

ghost avatar Nov 09 '20 18:11 ghost

Hi,

A GeoJSON polygon must start and end with the same point.

Try this:

{"type":"Polygon","coordinates":[[[7.446993, 51.510959],[7.450195, 51.511600],[7.450066, 51.507620],[7.446867, 51.508127],[7.446993, 51.510959]]]}

tidwall avatar Nov 09 '20 21:11 tidwall

Thank you, man. Love you so much

anhtu91 avatar Nov 10 '20 08:11 anhtu91