1

I have two shapefiles. One contains a raster with grid cells and the other administrative boundaries. I would like to union the polygons from both layers but geoprocessing - union yields the following error:

Processing algorithm…
AlgorithmDialog
Input parameters:
{ 'INPUT' : '/ne_10m_admin_1_states_provinces/ne_10m_admin_1_states_provinces.shp', 'OVERLAY' : 'split.shp', 'OUTPUT' : 'memory:' }

Traceback (most recent call last): File "C:/PROGRA~1/QGIS3~1.0/apps/qgis/./python/plugins\processing\algs\qgis\Union.py", line 94, in processAlgorithm indexA = QgsSpatialIndex(sourceA, feedback) Exception: unknown 

Execution failed after 0.19 seconds


Loading resulting layers
Algorithm 'Union' finished

enter image description here

4
  • 3
    A shapefile is vector file and cannot be a raster "One contains a raster with grid cells and the other administrative boundaries". Your question is confusing, please clarify.
    – artwork21
    Mar 8, 2018 at 13:40
  • 1
    Sounds like you want to Intersect them.
    – BERA
    Mar 8, 2018 at 13:42
  • Thanks ... sometimes it's just the buzzword that I am missing. I'll check it out
    – Stücke
    Mar 8, 2018 at 14:01
  • I think the buzzwork I am looking for is 'union' (vector - geoprocessing - union)
    – Stücke
    Mar 8, 2018 at 14:07

1 Answer 1

2

There are three common reason why a geoprocessing algorithm fails.

  1. Incorrect input types. Both input files must be vector layers of the same geometry type.
  2. Projection issue. Both input files must be in the same coordinate reference system.
  3. Invalid geometries, e.g. duplicate vertex points, self-intersecting polygon border or lines. Use topology checker to find invalid geometries. Fix them manually, or with v.clean command (found in Processing Toolbox under GRASS; must be running "QGIS Desktop with GRASS").

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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