Tuesday 29 May 2018

qgis - ST_MakeValid is not working?


I have a polyline spatialite database, tried to perform repair geometry in QGIS using python with the following code:


from pyspatialite import dbapi2 as db

conn = db.connect(r'D:\db.sqlite')
cur = conn.cursor()


repairGeometry = "UPDATE the_table SET GEOMETRY = ST_MakeValid(GEOMETRY) WHERE ST_IsValid(GEOMETRY) = 0;"
rs = cur.execute(repairGeometry)

I am getting this error:


rs = cur.execute(repairGeometry)
OperationalError: no such function: ST_MakeValid


No comments:

Post a Comment

arcpy - Changing output name when exporting data driven pages to JPG?

Is there a way to save the output JPG, changing the output file name to the page name, instead of page number? I mean changing the script fo...