<div dir="ltr"><div>A programmatic join in 2.6.x using the following:<br><br>joinIdx = joinLyr.fieldNameIndex('siteid')<br>targetIdx = pamLyr.fieldNameIndex('siteid')<br>joinLyrId = joinLyr.id() <br>joinInfo = QgsVectorJoinInfo()<br>joinInfo.memoryCache = True<br>joinInfo.joinField = joinIdx<br>joinInfo.joinLayerId = joinLyrId<br>joinInfo.targetField = targetIdx<br>pamLyr.addJoin(joinInfo)<br><br>Works
fine in Linux, but not in Windows. In windows if you look at the join
in properties on the layer, the targetField is missing. The fields from the joined layer show up in the attributes in the target layer but have no values. <br><br></div>Any help would be greatly appreciated.</div>