Bug report #12589

Choose which fields are joined behaves wrongly when the target field is also selected

Added by Giovanni Allegri almost 9 years ago. Updated almost 9 years ago.

Status:Closed
Priority:High
Assignee:-
Category:Vectors
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

Description

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.

Associated revisions

Revision 78708159
Added by Martin Dobias over 8 years ago

Fix shifted joined attributes when join field is repeated (fixes #12589)

Revision 5c2f9e67
Added by Martin Dobias over 8 years ago

Fix shifted joined attributes when join field is repeated (fixes #12589)

(cherry picked from commit 78708159b28bcbfa94e53f8b93f91790fa43ec02)

History

#1 Updated by Giovanni Allegri almost 9 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 almost 9 years ago

  • Pull Request or Patch supplied changed from No to Yes

#3 Updated by Martin Dobias almost 9 years ago

  • Status changed from Open to Closed

Also available in: Atom PDF