[postgis-users] Creating a boundary of an aggregate of buildings

Luca Bertoncello lucabert at lucabert.de
Mon Jan 18 02:33:26 PST 2021


Am 18.01.2021 10:51, schrieb Tomas Straupis:

Hi Tomas

>   Have not tested your statement, but besides missing comma between
> 1000 and 'quad_segs=1' looks fine.
>   I use such buffering for landuse (forest, water) aggregation for
> different scales.

So this is my query:

           (SELECT ST_Buffer(ST_Buffer(way, 1000, 'quad_segs=1'), -1000, 
'quad_segs=1') as way
             FROM
               (SELECT way, ST_ClusterDBSCAN(way, eps := 1000, minpoints 
:= 2) OVER () AS cid
                FROM planet_osm_polygon
                WHERE landuse IN ('residential', 'retail', 
'retail;residential', 'commercial', 'school')
               ) a
           ) AS test

unfortunately it does not work as expected, since I have always many 
many many little areas...

Any other idea?

Thanks
Luca Bertoncello
(lucabert at lucabert.de)


More information about the postgis-users mailing list