Bug report #19931
The "iterate over this layer" button is missing for the "Extract selected features" algorithm input layer
Status: | Rejected | ||
---|---|---|---|
Priority: | High | ||
Assignee: | Nyall Dawson | ||
Category: | Processing/QGIS | ||
Affected QGIS version: | 3.3(master) | Regression?: | Yes |
Operating System: | Easy fix?: | No | |
Pull Request or Patch supplied: | No | Resolution: | invalid |
Crashes QGIS or corrupts data: | No | Copied to github as #: | 27754 |
Description
The other "extract by ..." algorithms seem to have the green button to iterate over the layer; not that one.
Set as regression because the "save selected features" in 2.18 has the button.
History
#1 Updated by Giovanni Manghi about 6 years ago
- Priority changed from Normal to High
#2 Updated by Nyall Dawson about 6 years ago
- Status changed from Open to In Progress
- Assignee set to Nyall Dawson
#3 Updated by Nyall Dawson about 6 years ago
- Status changed from In Progress to Rejected
- Resolution set to invalid
I've looked into this -- while the button exists in 2.18, it has absolutely no meaning. In iterating mode a temporary layer is created for each feature in the selected layers, and this temporary layer has no selection in it! So running in 2.18 always results in the incorrect error message: "There are no selected features in the input layer.".
I think the 3.x behavior is preferable here, and we should continue to hide the button.
#4 Updated by Harrissou Santanna about 6 years ago
I'm not sure I understand: in 2.18, the tool would be buggy so it should not be ported and fixed in 3.x?
The question was raised in a french forum by someone who wanted to select features in a layer (no particular rule of selection) and output each to geojson. What would then be the appropriate and quick way to do this in 3.x?
#5 Updated by Nyall Dawson about 6 years ago
Well, making it working is non-trivial, to say the least. I can "fix" it and re-add the button, but it'll continue to be useless/misleading/a cause of user frustration.
Truth is - there's no regression here. Outputting selected features to individual layers isn't any more difficult in 3.x than 2.x. I think the easiest way to do this would be as a two step approach by first saving/copying the selected features to a new layer, and then iterating over that layer.