I'm trying to add polygon attributes to a point file with a lot (~370,000) of points in QGIS v3.0.0. I first tried using the point sampling tool, which I've used with success pulling the values from raster files, but this became unresponsive and remained so for several hours.

A search pointed me to the Saga add polygon attributes to points from the processing toolbox, and reported it to be much faster than join attributes by location see this post by @Underdark link. This completed quickly but failed to create or add a layer. I got a similar error as @Tali in this question. I followed the multipart to singlepart suggestion, but to no effect- my polygons were all initially single part features. I also ran v.build.check to see if I had any other topological errors in my polygon file, but found none.

The error message I get is: error message

I can do other processing tasks with the point layer, and tried both in and out of edit mode. The tool works fine with the same polygon layer and a much smaller point files (~400 pts), but still failed when I used a ~200k point subset. I've tried re-running with the output set to save as both as shapefile and as geopackage, but get the same result. I converted both my point and region files to geopackages and tried again, with the same error. I also tried in a blank map document with only the two files and get the same error.

Any ideas on how to resolve the error with the add polygon attributes to points, or an alternate tool that could accomplish the same thing in a reasonable amount of time?

  • Have you tried saving the output to disk instead of as a temporary layer? – Joseph Mar 21 '18 at 15:59
  • 1
    Any chance you could share your data? – ndawson Mar 21 '18 at 20:09
  • @Joseph I've tried saving output to disk in both geopackage and shapefile formats. – Brian Fisher Mar 21 '18 at 22:20
  • @ndawson I posted the files to dropbox and edited the question to add the link. Data converted to geopackage for transfer and tested. I'm still getting the same error. – Brian Fisher Mar 21 '18 at 22:41
  • Thanks. Using QGIS 3.0, the "Join attributes by location" tool worked fine for me (took 16 seconds). – ndawson Mar 21 '18 at 23:21

Your Answer

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

Browse other questions tagged or ask your own question.