Bug report #7952
Merging of shapefiles looses attribute values when the size if different
|Affected QGIS version:||master||Regression?:|
|Operating System:||Easy fix?:|
|Pull Request or Patch supplied:||No||Resolution:|
|Crashes QGIS or corrupts data:||No||Copied to github as #:||16815|
I try to merge shapefiles in the new qgis-dev.
For the string attributes it creates the new shapefile is using the size of the first shapefile i see.
This is potentially wrong because if the other shapefiles has a size greater than the first the
merge operation leave it NULL.
An use case:
when producing the index-location using the gdaltindex utility.
It produces a single shapefile with the size needed for describe the paths.
If the user needs to merge all the index shapefile produced.
This operation this quite common in mapserver.
The operation fails in qgis because the string size of field location is never equal to the other index shapefiles.
I guess same thing can happen using the qgis-server.
The issue is in the merge operation that actually requires that all the shapefiles have the same size on same field.
Instead it should apply the greater size between the shapefiles merged.