[postgis-users] Postgis topology issue

francescoboccacci at libero.it francescoboccacci at libero.it
Thu Feb 9 08:01:15 PST 2012


Hi all,
i'm "playing" with Postgis 2.0 Topology function and i like it.. but i receive 
this error:

********** Error **********

ERROR: SQL/MM Spatial exception - point not on edge
SQL state: P0001
Context: PL/pgSQL function "topogeo_addpoint" line 66 at assignment
PL/pgSQL function "topogeo_addlinestring" line 111 at assignment
SQL statement "SELECT array_cat(edges, array_agg(x)) FROM ( select topology.
TopoGeo_addLinestring(atopology, rec.geom, tolerance) as x ) as foo"
PL/pgSQL function "topogeo_addpolygon" line 23 at assignment
SQL statement "INSERT INTO sample1.relation(topogeo_id, layer_id, 
element_type, element_id) SELECT 5, 1, 3, topogeo_addPolygon('sample1', 
'0103000000010000000A00000000000080AB6829413789412068EB284137894160A9682941000000002BEB2841C976BEDFA5682941000000C0C0EA2841C976BE1FA4682941378941A08AEA28410000008049682941378941A08DEA2841C976BE5F4B68294100000080C5EA2841000000804B68294100000080C7EA2841000000004F682941000000402FEB28410000000051682941000000406BEB284100000080AB6829413789412068EB2841'::
geometry, 0);"
PL/pgSQL function "totopogeom" line 125 at EXECUTE statement



these are my query that are "copy and paste " from 

http://postgis.refractions.net/pipermail/postgis-users/2012-January/032169.
html

--Create new togology ---
SELECT CreateTopology('sample1');

--Add topoGeomColumn---
SELECT AddTopoGeometryColumn('sample1',
                              'public', 'small_polygon', 'topogeom',
                              'POLYGON');


                              
UPDATE small_polygon SET topogeom = toTopoGeom(the_geom, 'sample1',1);

Do you have any suggestion? maybe i used a a wrong geometry..

Thanks

Francesco



More information about the postgis-users mailing list