Bug report #14235

Merge selected features tool corrupts data when columns are defined as "hidden"

Added by David Beni - arx iT about 1 year ago. Updated about 1 year ago.

Status:Closed Start Date:02/05/2016
Priority:High Due date:
Assigned to:Nyall Dawson % Done:

0%

Category:Digitising
Target version:-
Platform: Pull Request or Patch supplied:No
Platform version: Affected version:master
Status info: Causes crash or corruption:Yes
Resolution: Tag:

Description

This bug concerns the "Merge selected features" tool from the "Advanced Digitizing Toolbar". A sample project is enclosed with the report to reproduce.

Steps :
  1. Open the enclosed project
  2. Zoom to the "BATIMENT" layer, there are 2 features overlapping
  3. Turn on editing on this layer
  4. Select the two features
  5. Select the "Merge selected features" tool from the "Advanced Digitizing Toolbar"
  6. Keep the default settings in the merge dialog
  7. Validate to launch the merge
    The features are deleted, no new features created
  8. Open the "BATIMENTS" layer properties, go to the "Fields" section
  9. For the "ImportId" field, set the editor widget to "Text editor", instead of "Hidden"
  10. Validate and close the properties
  11. Merge again the 2 features with the defaults settings
    The merge is now working

The problem seems to come from this hidden "ImportId" field, because if you make the test with the "OGC_FID" field, the merge works in all cases.

MergeBug.zip - Project to reproduce the bug (330.4 kB) David Beni - arx iT, 02/05/2016 02:42 am

Associated revisions

Revision 1566e37a47e5ea7c87abb692549ecb7a661aa147
Added by Nyall Dawson about 1 year ago

Fix merge attribute dialog mangles field values when layer has hidden
fields (fix #14235)

History

Updated by Giovanni Manghi about 1 year ago

  • Subject changed from Merge selected features tool deletes features in certain case to Merge selected features tool corrupts data when columns are defined as "hidden"
  • Priority changed from Normal to High
  • Platform deleted (Windows)
  • Platform version deleted (8.1)
  • Causes crash or corruption changed from No to Yes

Does not seems to happen just in special cases... any time you have an hidden column that is not the PK this operation will lead to this data corruption...

Updated by Nyall Dawson about 1 year ago

  • Assigned to set to Nyall Dawson

Updated by Nyall Dawson about 1 year ago

  • Status changed from Open to In Progress

Updated by Nyall Dawson about 1 year ago

  • Status changed from In Progress to Closed

Also available in: Atom