Bug report #12589
Choose which fields are joined behaves wrongly when the target field is also selected
|Affected QGIS version:||2.8.1||Regression?:||No|
|Operating System:||Easy fix?:||No|
|Pull Request or Patch supplied:||Yes||Resolution:|
|Crashes QGIS or corrupts data:||No||Copied to github as #:||20713|
If the target vector is selected from the fields to be joined, it isn't added in the headers but the field contents are shifted one column.
e.g. if my target field is FIELD_1 and I choose as joined fields FIELD_1 and FIELD_2 I obtain a FIELD_2 header containing the FIELD_1 values.
If I select more fields the problem has a cascading effect on the other fields too.
#1 Updated by Giovanni Allegri over 5 years ago
I haven't a patch yet but the problem can be easily solved removing the target layer from the layers list here: https://github.com/qgis/QGIS/blob/master/src/app/qgsjoindialog.cpp#L141
#2 Updated by Giovanni Allegri over 5 years ago
- Pull Request or Patch supplied changed from No to Yes
I have a patch ready for PR on my github repo: https://github.com/giohappy/QGIS/commit/c470432008300306da27e5132151a0ab8e0b2754