[postgis-users] Merge rectangles
lr at pcorp.us
Thu Aug 16 11:54:07 PDT 2012
You don't need to do array unless you have a reason for that LIMIT.
ST_Union is an overloaded function: One version is an aggregate and one
takes an array of geometries.
So below is a bit shorter to write:
WHERE cat.type = 'CADRG';
From: postgis-users-bounces at postgis.refractions.net
[mailto:postgis-users-bounces at postgis.refractions.net] On Behalf Of DrYSG
Sent: Wednesday, August 15, 2012 2:39 PM
To: postgis-users at postgis.refractions.net
Subject: [postgis-users] Merge rectangles
In the table portal.catalog
column poly is a geometry (always a rectangle, with datum EPSG 4326) column
type is a text field.
I want to find all the records who have a type of "CADRG" and merge the
polygons into the simplest shape that covers all the items in the array
(I.e. if they form a square with a hole, then I want that, if it has to be a
multipolygon, so be it).
Is this the correct way to do that?
FROM portal.catalog as cat
View this message in context:
Sent from the PostGIS - User mailing list archive at Nabble.com.
postgis-users mailing list
postgis-users at postgis.refractions.net
More information about the postgis-users