[postgis-users] Difficulty for finding Intersection using postGIS
Saranya Sari
saranyak578 at gmail.com
Thu Mar 30 04:53:11 PDT 2017
Hai,
When I run my code, each time the memory reaches its limit and the system
gets stuck. There is no output. This is my code. I am using PostGIS from
psycopg2.
iin="""WITH a AS (
SELECT * FROM alappuzhanew1
WHERE filename = 'part3'
AND ST_IsValid(geom::geometry)),
b AS (
SELECT * FROM alappuzhanew2
WHERE filename = 'part4'
AND ST_IsValid(geom::geometry))
SELECT
CASE
WHEN ST_CoveredBy(a.geom, b.geom)
THEN a.geom
WHEN ST_CoveredBy(b.geom, a.geom)
THEN b.geom
ELSE
ST_Intersection(a.geom, b.geom)
END as geom
FROM a,b ;"""
curs.execute(iin)
Is there any fault with the code. Please help me....
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20170330/e1ed3413/attachment.html>
More information about the postgis-users
mailing list