Bug report #14532
Dissolve and Spatial Query doesn't work
|Affected QGIS version:||2.14.0||Regression?:||No|
|Operating System:||Easy fix?:||No|
|Pull Request or Patch supplied:||No||Resolution:|
|Crashes QGIS or corrupts data:||No||Copied to github as #:||22505|
I have a problem with the Dissolve tool and Spatial query.
I have a multipart polygon, created using dissolve tool, and a shp of points.
If I use "spatial query" and ask how many points are contained in these polygons, the results is 0, but this is not true.
The reference system is the same for all the layers (EPSG: 3003).
I have attached 3 shp:
-Centroidi (points layer)
-VenetoreclassOK (the source polygon layer)
-DissolveDN (the results of the Dissolve by the field DN)
Let's try another way to describe better the problem.
If I select, in the shp named DissolveDN, the DN categories 3 and 4, and than, using Spatial Query, I ask how many points are within the categories 3 and 4, the results is 0. By the way if I did the same spatial query selecting categories 1 or 2, the tool works.
Really I don't understand why.
Please help me to figure out this issue. I have tryed with QGIS 2.14 and 2.8.7.
thanks a lot
#5 Updated by Anita Graser over 5 years ago
- Category set to Processing/QGIS
I now tried three dissolve algorithms in the Processing toolbox:
- QGIS Dissolve: The result didn't even contain all input features
- SAGE Dissolve: Looked ok but Spatial Query didn't select any centroids as "within"
- GRASS Dissolve: This worked! Spatial Query selected 590 out of 591 as "within" (one is slightly outside of the polygons)
#7 Updated by Maximilian Krambach over 5 years ago
As to why QGIS Dissolve leaves out output: GEOS:combine (which is used by QGIS:dissolve) returns eight geometry errors, and in the output eight polygons are missing. I guess that QGIS:dissolve only writes "correct" geometries as output. Those "defect" geometries are cases where an inner ring touches the outer ring.