[postgis-tickets] [PostGIS] #4182: Unexpected TopologyException during ST_Union aggregate function with valid polygons

PostGIS trac at osgeo.org
Thu Aug 22 05:49:19 PDT 2019


#4182: Unexpected TopologyException during ST_Union aggregate function with valid
polygons
-----------------------+--------------------------
  Reporter:  blaggner  |      Owner:  pramsey
      Type:  defect    |     Status:  new
  Priority:  medium    |  Milestone:  PostGIS GEOS
 Component:  postgis   |    Version:  2.3.x
Resolution:            |   Keywords:
-----------------------+--------------------------

Comment (by fengel):

 I have similar TopologyExceptions on valid geometries quite often and I am
 looking forward to the approvements that are on the way in JTS and GEOS.
 In my experience large polygon tables in the real world (data from
 institutions, geo portals etc.) are very often subject to this kind of
 problem. Since the exception results in aborting the process it can become
 quite problematic if you have to come up with a solution.
 I was wondering if there are any recommendations for workarounds to this
 issue. I currently use the functions st_safe_difference and
 st_safe_intersection from this extension at the moment:
 https://pgxn.org/dist/lostgis/1.0.2/ plus a self created safe_union
 function. The main mechanism is exception handling which allows you to
 ignore exceptions that cannot be solved. Using these functions I was able
 to work with any kind of data so far and I didn't notice any major
 drawbacks. But I am not sure if these solutions are reasonable and it
 would be very interesting to see workaround strategies from other people.

-- 
Ticket URL: <https://trac.osgeo.org/postgis/ticket/4182#comment:8>
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-tickets mailing list