[mapserver-users] Calculate length!
Rahkonen Jukka (MML)
jukka.rahkonen at maanmittauslaitos.fi
Mon Mar 16 05:33:23 PDT 2015
Hi,
The GDAL version is not what is essential but the version of the dependent Spatialite library. GDAL must be compiled with such Spatialite version that has support for ST_Length. The error means either that Spatialite is missing totally or that it is of too old version and in this case it is obvioustly the latter. However, there may be a simple solution. ST-functions are new synonyms but your older Spatialite version may support the native name that Spatialite has used for the function https://www.gaia-gis.it/gaia-sins/xmlBlob/spatialite-sql-latest.html.
Try if SELECT glength(geometry) happens to work. Otherwise you must try to find a GDAL version that is compiled with more fresh Spatialite.
-Jukka Rahkonen-
Schylberg Lars wrote:
I guess this must be a version problem. That same command runs fine on my osgeolive8 machine.
ogrinfo --version
GDAL 1.10.1, released 2013/08/26
/Lars
From: mapserver-users-bounces at lists.osgeo.org<mailto:mapserver-users-bounces at lists.osgeo.org> [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of alok mathur
Sent: den 16 mars 2015 09:54
To: Rahkonen Jukka (MML); mapserver-users at lists.osgeo.org<mailto:mapserver-users at lists.osgeo.org>
Subject: Re: [mapserver-users] Calculate length!
Hi Jukka,
When i am trying to run the above ogr command as mentioned by you I am getting an error
ogrinfo -dialect sqlite -sql "select st_length(geometry) from 'Fibertech solution'" doc_test.kml
INFO: Open of `doc_test.kml'
using driver `LIBKML' successful.
ERROR 1: In ExecuteSQL(): sqlite3_prepare(select st_length(geometry) from 'Fibertech solution'):
no such function: st_length
Please let me know what the issue is. I have installed both libsqlite3 and libspatialite.
Thanks!
Alok
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20150316/a1fd42f3/attachment.htm>
More information about the MapServer-users
mailing list