Bug report #9424

Attribute table editing writes simultaneously in the selected column for sorting

Added by Bogdan Hlevca about 10 years ago. Updated about 10 years ago.

Status:Closed
Priority:Severe/Regression
Assignee:-
Category:Vectors
Affected QGIS version:master Regression?:No
Operating System: Easy fix?:No
Pull Request or Patch supplied:No Resolution:
Crashes QGIS or corrupts data:No Copied to github as #:18018

Description

When editing the Attribute table of a vector layer writing the value in a column will automatically update that value also in the column that is selected for sort.

The workaround so far is either to select the column you are editing, but it is cumbersome when you have multiple columns to edit in for a large number of points

or

create a bogus column which you keep selected for sorting and delete it when job is done.

Associated revisions

Revision 5f1c8f49
Added by Matthias Kuhn about 10 years ago

[attrtable] Don't update sort column cache when unaffected
Fix #9424

History

#1 Updated by Giovanni Manghi about 10 years ago

  • Category set to Vectors
  • Priority changed from Normal to Severe/Regression
  • Target version set to Future Release - High Priority
  • Affected QGIS version changed from 2.0.1 to master

Confirmed in master, a huge regression that must be fixed before the new release.

#2 Updated by Giovanni Manghi about 10 years ago

please note that the values in the column used for ordering are not (over)written after pressing "save", anyway even during editing operations the values in other columns should not change.

#3 Updated by Matthias Kuhn about 10 years ago

  • Status changed from Open to Feedback

I am not sure I understand this report.

Are you saying, that when you edit an attribute in the attribute table, it should not automatically be updated? Because it automatically updates the order of items with the new value and that interrupts the workflow?

Giovanni, which "save" button are you referring to?

#4 Updated by Giovanni Manghi about 10 years ago

Hi Matthias

Are you saying, that when you edit an attribute in the attribute table, it should not automatically be updated? Because it automatically updates the order of items with the new value and that interrupts the workflow?

no, the issue in another. Steps:

) open table
) order attributes using column "A"
) update (with field calculator) the values of column "B"
) the result is that new values are placed in both A and B, but after clicking "save edits" the values in "A" are "discarded" and original values are "restored".

It is not a issue causing data corruption, but it makes a lot of confusion.

cheers!

#5 Updated by Leyan Ouyang about 10 years ago

I also met this issue, very confusing to see random data changed in the table, even if the underlying data is not affected.

This happens both in Windows and Linux versions of the latest master.

The update does not have to be done using the field calculator, it can be direct edit in the table.

#6 Updated by Giovanni Manghi about 10 years ago

  • Status changed from Feedback to Open

#7 Updated by Matthias Kuhn about 10 years ago

  • Status changed from Open to Closed

#8 Updated by Matthias Kuhn about 10 years ago

Outch, that was a bad one indeed. Sorry for that.

Also available in: Atom PDF