[postgis-users] ERROR: GEOS difference() threw an error!

Andreas Laggner andreas.laggner at fal.de
Tue Oct 9 05:49:30 PDT 2007


can someone tell me what causes this Error?

ERROR: GEOS difference() threw an error!
SQL Status:XX000

the query:
INSERT INTO test_natura_full
SELECT 
ffh_singlerep.ffh_name,ffh_singlerep.ffh_land,ffh_singlerep.ffh,ffh_singlerep.ffh_id, 

    null as spa_name,null as spa_land,null as spa,null as spa_id,
    ST_Difference(ffh_singlerep.the_geom, test_natura_full.the_geom) As 
the_geom
FROM ffh_singlerep INNER JOIN (SELECT ffh_id, ST_union(the_geom) As 
the_geom
    FROM test_natura_full GROUP BY ffh_id) As test_natura_full ON 
ffh_singlerep.ffh_id = test_natura_full.ffh_id
    AND ST_Intersects(ffh_singlerep.the_geom, test_natura_full.the_geom)
WHERE ST_IsEmpty(ST_Difference(ffh_singlerep.the_geom, 
test_natura_full.the_geom)) = false
UNION
SELECT null as ffh_name,null as ffh_land,null as ffh,null as ffh_id,
    
spa_singlerep.spa_name,spa_singlerep.spa_land,spa_singlerep.spa,spa_singlerep.spa_id, 

    ST_Difference(spa_singlerep.the_geom, test_natura_full.the_geom) As 
the_geom
FROM spa_singlerep INNER JOIN  (SELECT spa_id, ST_union(the_geom) As 
the_geom
    FROM test_natura_full GROUP BY spa_id) As test_natura_full ON 
spa_singlerep.spa_id = test_natura_full.spa_id
    AND ST_Intersects(spa_singlerep.the_geom,test_natura_full.the_geom)
WHERE ST_IsEmpty(ST_Difference(spa_singlerep.the_geom, 
test_natura_full.the_geom)) = false;


I had no problems with a small dataset (15 and 4 polygons), here i have 
28000 and 1500 rows. All geometries are valid and singlepart Polygons.

Cheers      Andreas


-- 
Dipl. Geoökologe Andreas Laggner
Institut für Ländliche Räume (LR)
Bundesforschungsanstalt für Landwirtschaft (FAL)

Institute of Rural Studies
Federal Agricultural Research Centre (FAL)

Bundesallee 50
D-38116 Braunschweig

Tel.: (+49) (0)531 596 5515
Fax: (+49) (0)531 596 5599
E-mail: andreas.laggner at fal.de
Homepage: http://www.lr.fal.de/ 




More information about the postgis-users mailing list