[postgis-users] What can i do if polygons are not valid????

Frank Koormann frank.koormann at intevation.de
Fri Aug 17 02:14:55 PDT 2007


Hi,

* Andreas Laggner <andreas.laggner at fal.de> [070817 11:05]:
> Hi,
> 
> who can tell me something about the error? It occurs with this 
> statements and i guess it is because 122 polygons from ffh are not valid!
> 

You can check this if you limit your processing to the valid, by adding

AND isvalid(t1.the_geom) AND isvalid(t2.the_geom)

to your where clause.

> ffh 27000 rows (122 not valid), spa 1800 rows
> 
> Are there any possibilities to repair ffh or what else can i do????

A usual recommendation to try to fix invalid polygons is 

buffer(the_geom,0.0)

see e.g.
http://postgis.refractions.net/pipermail/postgis-users/2007-May/015766.html

Regards,

        Frank

-- 
Frank Koormann    |   ++49-541-335 08 30    |   http://www.intevation.net/
Intevation GmbH, Osnabrück, DE | Commercial Register Osnabrück, HR B 18998
Managing Directors: Frank Koormann, Bernhard Reiter, Dr. Jan-Oliver Wagner
PostGIS Support (http://www.intevation.net/geospatial/postgis-support.en.html)



More information about the postgis-users mailing list