6

While running topology against two identical polygon (parcel) datasets in ArcGIS and QGIS, QGIS detects errors that ArcGIS does not. In four separate instances in my township-wide parcel dataset QGIS flags "invalid geometry" (screenshot 1) where two island polygons touch at a point within the larger containing polygon (screenshots 2 and 3). Notice that QGIS does not have an issue with a number of island polygons as long as they do not touch each other (adjacent parcel to the NE in screenshots 1 & 2).

Why is this an invalid geometry error?

screenshot 1

screenshot 2

screenshot 3

7
  • 1
    which version of QGIS, and are you using the standard geometry checker? Also, have you tried making the error column wider, in case you're only seeing part of the message?
    – Steven Kay
    Dec 21 '16 at 19:15
  • QGIS 2.18.1 64-bit on Windows 10. I am using the Topology Checker -- the one available from the Vector pull-down menu. I am seeing the full message, I just cropped the screenshot. The message displays the error type ("invalid geometry"), layer name (very long PostGIS feature class), and the Feature ID. @StevenKay Dec 21 '16 at 19:27
  • 2
    ah, that plugin was disabled on my setup. You could try Vector > Geometry > Check Validity, that should output several layers with error features split out, and (hopefully) more descriptive messages.
    – Steven Kay
    Dec 21 '16 at 19:44
  • 1
    I have found that making a very trivial buffer (0.0001 of a metre) into a new layer has fixed errors like this for me in the past. ciao
    – BillW
    Dec 22 '16 at 3:00
  • 1
    Using QGIS 2.1821 I also faced the same problem, and ended using the combination Vector > Geometry > Check Validity suggested by @steven-kay and then I repaired the problems in the "Invalid Output" generated layer using the Grass v.buffer.distance with 0.00001m in both parameters (buffer distance... and maximum distance between...) as suggested by billw. Thanks
    – nanunga
    Jun 26 '18 at 0:49
5

This is a partial answer, summarizing the comments to my original question and my experience following the commenters' recommendations:

  • The "Topology Checker" and "Geometry -> Check Validity" tools generate different outputs
  • "Geometry -> Check Validity" generates three output layers with much more descriptive output regarding what might be wrong with the data
  • The particular issue I am experiencing might be related to bug #15377

Thanks to Steven Kay and eclipsed_by_the_moon.

ADDED on 2016-12-23: Editing the data to make the island polygons not touch (see screenshot) makes the "invalid geometry" error go away. In other words, QGIS considered my initial example a self-intersecting polygon, and therefore an invalid geometry (an error), even though this is a perfectly legitimate configuration in parcel fabric mapping.

For the record, as mentioned in the original question, ArcGIS does not flag this instance as an error. I had tagged my question with "arcgis" in addition to "qgis" in order to make that point, but a moderator removed the "arcgis" tag.

"invalid geometry" error resolved

2
  • Is it possible to split the polygon using the split features tool? Maybe the 'Check geometries' plugin can help to find a geometry error. Dec 21 '16 at 21:08
  • QGIS does not allow me to split the feature because "the geometry is invalid", @eclipsed_by_the_moon . I'll keep investigating. The strange part is that ArcGIS does not detect any errors on an identical dataset... Dec 21 '16 at 21:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.