I have a point shapefile and a CSV file containing various attributes and three columns (here: street
,num
,addnum
) based on which I would like to join both tables like
attribute1;...;attributen;street;num;addnum
1;...;100;Goethestr.;10;A
Since 'Straße' might be abbreviated or not and lower/uppercase might not be used consistent, I generate a virtual field adr
for each table upon wich I'd like to build a join by an expression like
replace(lower(if("addnum" is null, "street" || "num", "street" || "num" || "addnum")),'str.','straße')
I create a join on the point shapefile like this:
but as a result I get NULL
values for the prefixed joined attributes/fields:
What might be the problem? Virtual fields not suitable for joins? [QGIS 2.14.5LTR]
-
2Works fine for me (tested on QGIS 2.16.1). This issue was reported and fixed a few months ago so perhaps try the latest QGIS 2.14.7 LTR or indeed QGIS 2.16 ;)Joseph– Joseph2016年10月19日 12:40:10 +00:00Commented Oct 19, 2016 at 12:40
-
2You can't imagine how valuable this comment is to me. Our IT service provider is in the opinion that it is not necessary to update the LTRs, thats why 2.14.5, and this strongly helps me argue not to keep old versions :-) +1.Jochen Schwarze– Jochen Schwarze2016年10月19日 12:58:13 +00:00Commented Oct 19, 2016 at 12:58
-
1Let's hope they listen to you! =)Joseph– Joseph2016年10月19日 13:00:35 +00:00Commented Oct 19, 2016 at 13:00
-
they do, at least they're working on it!!! @Joseph if I should meet you irl some day, i buy you a beer ;-)Jochen Schwarze– Jochen Schwarze2016年11月24日 13:56:34 +00:00Commented Nov 24, 2016 at 13:56
-
Great! That's good news! And I would very much look forward to it ;)Joseph– Joseph2016年11月24日 13:59:31 +00:00Commented Nov 24, 2016 at 13:59
1 Answer 1
As mentioned in my comment, this works for QGIS 2.16. I also downloaded and tested this on QGIS 2.14.7 LTR and it works too.
So virtual fields are suitable for joins, you just need to upgrade ;)
-
1easier said then done...Jochen Schwarze– Jochen Schwarze2016年10月20日 12:33:59 +00:00Commented Oct 20, 2016 at 12:33
Explore related questions
See similar questions with these tags.