[QGIS-it-user] QGIS e

Enrico Fiore enricofiore a libero.it
Mer 14 Feb 2018 01:51:41 PST


Ciao,

scusate se mi intrometto, ma perchè occorre creare un nuovo campo geometry. non si può utilizzare direttamente CastToMultiPolygon() nella query di partenza?

select COMUNE, CastToMultiPolygon(st_intersection (clc.geom, com.geom)) as geom, count (*)as
nro,
(sum (st_area( st_intersection (clc.geom, com.geom)))/st_area(com.geom))
as
indice
from CLC_Molise clc, comuni_molise com
where liv_3 like 'Boschi %' and st_intersects (clc.geom, com.geom) = 1
group by 1
order by indice desc;

> 
>     Il 13 febbraio 2018 alle 16.41 Totò <pigrecoinfinito a gmail.com> ha scritto:
> 
>     pcav wrote
> 
>         > > 
> >         Probabilmente perché restituisce una geomertycollection?
> > 
> >     > 
>     SI, la query restituisce una geomertycollection cioè:
>     facendo un check della geometria ho due record; polygon e multipolygon;
> 
>     come scritto sopra, Furieri ha spiegato che basti creare un altro campo
>     geom2 e popolarlo forzando, come tipologia di geometria, multipolygon.
> 
>     saluti
> 
>     -----
> 
>     https://pigrecoinfinito.wordpress.com/
>     --
>     Sent from: http://osgeo-org.1560.x6.nabble.com/QGIS-Italian-User-f5250612.html
> 
>     _______________________________________________
>     QGIS-it-user mailing list
>     QGIS-it-user a lists.osgeo.org
>     https://lists.osgeo.org/mailman/listinfo/qgis-it-user
> 
-------------- parte successiva --------------
Un allegato HTML è stato rimosso...
URL: <http://lists.osgeo.org/pipermail/qgis-it-user/attachments/20180214/389411a8/attachment.html>


Maggiori informazioni sulla lista QGIS-it-user