Help with a query

Luca Bertoncello lucabert at lucabert.de
Sun Dec 22 11:46:11 PST 2024


Am 22.12.2024 um 18:33 schrieb Brent Wood:

Hi Brent,

> You might try adding a step to get the MultiPolygons from your
> Geometrycollection, see
> 
> https://postgis.net/docs/ST_CollectionExtract.html
> 
> Use type = 3 for polygons
> 
> UPDATE city_boundaries SET wayn3 =
> ST_Multi(ST_CollectionExtract(ST_Buffer(wayn2, -50, 'join=miter'),3));

I already found the way with ST_CollectionExtract...
My query is now:

UPDATE city_boundaries SET wayn4 =
ST_CollectionExtract(ST_Makevalid(wayn3), 3);

and it works good (rendered just now an area and checked that is works).

Thanks
Luca Bertoncello
(lucabert at lucabert.de)


More information about the postgis-users mailing list