[postgis-users] ST_AsGeoJson output geometry type not the same as input
Max Demars
burton449geo at gmail.com
Tue Sep 2 10:19:55 PDT 2014
Hi list,
I am using postgis to split a multipolygon feature by a linestring. Both
feature are geojson inputs.
However the outputs returns a geojson that is a geocollection of two
polygon features. In fact this is correct, but for consistency I would like
to keep the the splitted features into a single Multipolygon (even if there
is only one linear ring in it). Is it possible?
This is my query:
SQLQuery = '''SELECT
ST_AsGeoJSON(ST_Split(ST_GeomFromGeoJSON('%s'),ST_GeomFromGeoJSON('%s')))::json
As f''' % (feature,blade)
-Max Demars
--
Stack Overflow: http://stackoverflow.com/users/1914034/burton449
GIS Overflow: http://gis.stackexchange.com/users/14426/burton449
LastFm: http://www.lastfm.fr/user/burton449
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20140902/7a0e4196/attachment.html>
More information about the postgis-users
mailing list