[postgis-devel] [PostGIS] #788: Topology: ST_NewEdgesSplit don't work with more edges connected

PostGIS trac at osgeo.org
Tue Jan 18 12:13:23 PST 2011


#788: Topology: ST_NewEdgesSplit don't work with more edges connected
-----------------------+----------------------------------------------------
 Reporter:  aperi2007  |       Owner:  strk         
     Type:  defect     |      Status:  new          
 Priority:  medium     |   Milestone:  PostGIS 2.0.0
Component:  topology   |     Version:  trunk        
 Keywords:             |  
-----------------------+----------------------------------------------------
 Hi,
 I find a strange bug.

 Starting from an empty topology:
 DROP TABLE IF EXISTS SCHEMA_OUT.TEST;
 CREATE TABLE SCHEMA_OUT.TEST(ID INTEGER PRIMARY KEY, CODICE TEXT);
 SELECT topology.DropTopology('schema_topo');
 SELECT topology.CreateTopology('schema_topo',3003, 0.00005);
 SELECT topology.AddTopoGeometryColumn('schema_topo', 'schema_out', 'test',
 'topo_line', 'LINE');

 This code sql is working:
 ----
 select
 topology.AddEdge('schema_topo',ST_GeomFromEWKT('SRID=3003;LINESTRING(1 4,
 2 5, 3 5, 4 7)'));

 select topology.ST_newedgesSplit('schema_topo',1,
 ST_GeomFromEWKT('SRID=3003;POINT(3 5)'));
 ----
 but if the edge is connected to another edge.
 The code don't work.

 select
 topology.AddEdge('schema_topo',ST_GeomFromEWKT('SRID=3003;LINESTRING(1 4,
 4 4)'));

 select
 topology.AddEdge('schema_topo',ST_GeomFromEWKT('SRID=3003;LINESTRING(1 4,
 2 5, 3 5, 4 7)'));

 select topology.ST_newedgesSplit('schema_topo',1,
 ST_GeomFromEWKT('SRID=3003;POINT(3 5)'));

 giving this error:

  ERROR: SQL/MM Spatial exception - point not on edge

 I use the r6670 version of postgis trunk.

-- 
Ticket URL: <http://trac.osgeo.org/postgis/ticket/788>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.


More information about the postgis-devel mailing list