[postgis-devel] St_Intersection on same table

Rafal Foltynski rfolt at yahoo.com
Fri Apr 23 08:31:58 PDT 2010


Hi,

I have a table with many overlying polygons.  I want to create a new polygon relation from the intersection of these polygons that has two fields 1. geometry of small polygons - the result of St_Intersection() and 2. count of the number of overlying polygons that each small polygon was created from.  How do I create a query to run St_Intersect on the same geometry field in one table?

For example: if I have a table with 3 polygons, 2 of them share a small area and the third polygon is disjoint, the resulting polygon relation would only have one small polygon area (shared area between two polygons) and count of 2.   

Rafal    


      



More information about the postgis-devel mailing list