Hi, Thanks for all the suggestions. I found that a big part of the problem was that I had not set up indexes on the geometries. Once I did that, the functions worked much faster.
Regards, Loretta ----- Original Message ----- From: Paul Ramsey <[email protected]> Date: Friday, August 20, 2010 12:53 pm Subject: Re: [postgis-users] Problem cleaning invalid geometries > You could use ST_Dump() to split your multipolygon up and then run > validity check/fix on the individual components...? > P > > On Fri, Aug 20, 2010 at 9:44 AM, L Bogert-OBrien <[email protected]> > wrote:> Hi, > > > > I am just wondering if there is a way to minimize the extent on > which> the cleangeometry() function will act, or rewrite it so that > it only > > checks out the parts of the multipolygon near the problem area, > rather> than having to wait for it to check the validity of all the > pieces of > > the multipolygon. Then maybe I wouldn't have to wait days for it > to return. > > > > Any ideas? > > > > Thanks, > > > > Loretta > > > >>I am not sure what you are trying to say with this, but the geometry > >>that I am trying to clean is a multipolygon, not a collection. > Yes, it > >>is very big and has many points in the multipolygon, since it is the > > > >>Baffin region, but it is not a collection. ST_geometrytype returns > >>multipolygon for it. > > > > There are many possibly kind of invalidity. > > > > If the invalidity is a self-intersect, > > of course the ST_MakeValid() could split the polygon on the self- > intersect and produce another multipolygon with one more part. > > > > But if , for example, you multipolygon is invalid because it has > a hole of type Linestring, or because it has two part that are > touching along a line. > > > > More probably the st_makevalid could be return a > geometrycollection().> > > > > > > -- > > ----------------- > > Andrea Peri > > . . . . . . . . . > > qwerty àèìòùo > > ----------------- > > > > > > _______________________________________________ > > postgis-users mailing list > > [email protected] > > http://postgis.refractions.net/mailman/listinfo/postgis-users > > > > _______________________________________________ > > postgis-users mailing list > > [email protected] > > http://postgis.refractions.net/mailman/listinfo/postgis-users > > > > > _______________________________________________ > postgis-users mailing list > [email protected] > http://postgis.refractions.net/mailman/listinfo/postgis-users > _______________________________________________ postgis-users mailing list [email protected] http://postgis.refractions.net/mailman/listinfo/postgis-users
