I have a shapefile of Spanish municipalities downloaded here and another shapefile of functional urban areas (FUA) downloaded here.

I want to add to each municipality the urban area id if the municipality is inside a urban area. To do so, I go to the menu Vector > Data management tools > Join attributes by location with the following parameters :

  • target layer: Municipios
  • join vector layer: FUA
  • predicate: all checked
  • take attributes of the 1st located feature selected
  • Keep all records selected
  • Create a temporary layer selected

The columns of the joined layer which should contain the values from the FUA layer are all empty.

I've also checked the geometry on both layers, the municipalities one has 4 invalid polygons and even removing them, it is still not working.

What am I doing wrong ?

I had no problem before joining attributes on QGIS 2.14.


Since the shapefiles don't have the same projection, I guess you are working on the fly. If so, this is the reason why your attempt has failed. Re-project FUA_Boundaries in EPSG:3042 and then your request will be fine.

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.