[postgis-users] totopogeom resulting in SQL/MM Spatial exception

Bo Guo bo.guo at gisticinc.com
Wed Jan 16 09:26:12 PST 2019


strk,

Here is how it break up the topo geom conversion (l_tolerance is 0.0000001)

             LOOP
                 WITH foo AS (SELECT grd_id FROM azgiv.roadcenterlines
                                 WHERE grd_topo_geom IS NULL
                                     LIMIT l_batch_size)
                 UPDATE azgiv.roadcenterlines
                                 SET grd_topo_geom = 
topology.totopogeom(grd_geom, 'azgiv_topo', l_topo_layer_id, l_tolerance)
                                 FROM foo
                                 WHERE foo.grd_id = roadcenterlines.grd_id;

                 GET DIAGNOSTICS l_rowcount = ROW_COUNT;

                 EXIT WHEN l_rowcount < l_batch_size;

             END LOOP;

I ran into the following message:

    ERROR: SQL/MM Spatial exception - point not on edge CONTEXT:
    PL/pgSQL function totopogeom(geometry,topogeometry,double precision)
    line 112 at FOR over SELECT rows PL/pgSQL function
    totopogeom(geometry,character varying,integer,double precision) line
    88 at assignment

Please let me know if I am going in the right direction

Bo
On 1/16/19 10:03 AM, Sandro Santilli wrote:
> On Wed, Jan 16, 2019 at 09:53:28AM -0700, Bo Guo wrote:
>> strk,
>>
>> When I set the tolerance to 0.0000001 and it went through.  Is this a good
>> number to use generally?
> The smaller tolerance, the better, generally, I'd think.
> But learn how to spot small faces and edges, to clean them up, and how
> to load in chunks.
>
> --strk;
> _______________________________________________
> postgis-users mailing list
> postgis-users at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/postgis-users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20190116/9fea7741/attachment.html>


More information about the postgis-users mailing list