Bug report #12881
Incorrect Loading of Layer Group in Layer Definition File (*.qlr)
|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 #:||20972|
This issue is probably a little broader than this, but I can reproduce it in the following way:
- Add a layer from PostGIS with an SQL filter applied.
- Add another layer from PostGIS with a different SQL filter applied.
- Add both layers to a layer group.
- Save the layer group to a Layer Definition File (*.qlr).
- Load the *.qlr file into a non-empty project.
Every time I do it, the group loads with two layers, but the layers are always identical. In one case, it loaded the filter, the name and the style of the first layer twice. In another case it loaded the filter from one layer and the name from the other.
Fix #12881 - Fix loading of QLR files with the same layers
Using just date stamps wasn't fine enough
Funded By TechnologyOne, Australia
#2 Updated by weston mcarron about 5 years ago
I just reread my steps and realized I wasn't clear enough.
On step 2, the layer has to be from the same PostGIS table as in step 1, but with a different filter applied.
So two layers, both of which draw on the same PostGIS table.
Can you reproduce it that way?