Aggregate functions for TopoGeometries
Sandro Santilli
strk at kbt.io
Wed Nov 13 06:56:49 PST 2024
On Wed, Nov 13, 2024 at 12:44:26PM +0000, Felipe Matas wrote:
> I still I think would be nicer to work directly with TopoGeometries
> than TopoElements in this cases, is also more intuitive, there is a lot
> of advantages to use them :)
Concrete proposals are welcome, with example queries.
Right now you would do something like this:
INSERT INTO states (name, tgeom)
SELECT state_name, CreateTopoGeom(
'mytopo',
3, -- areal
layer_id(findLayer('states', 'tgeom'))
TopoElementArray_agg(tg::TopoElement)
)
FROM counties
GROUP BY state_name;
How would you make it more intuitive ?
--strk;
More information about the postgis-devel
mailing list