I'm trying to use ST_difference and ST_intersection with two layers of multipolygons.
I want something like:
With the input on the left and the result on the right.
t1.geom contains 1000 differents polygons.
t2.geom contains 1000 differents polygons.
I try to create (in a naive way) two queries to perform these operations
st_intersection(t1.geom, t2.geom) from t1,t2 where st_intersects(t1.geom,t2.geom);
Unfortunately it doesn't work, or takes forever to run.
I would like a query similar to the tools
intersect from ArcGIS.
How to perform those operations efficiently ?