Bug report #16481
Using @parent with aggregate doesn't return expected results
Status: | Feedback | ||
---|---|---|---|
Priority: | Normal | ||
Assignee: | - | ||
Category: | Expressions | ||
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 #: | 24389 |
Description
I have a polygon layer I would like to style according to the presence of features of another layer (site_concours).
Hence I used
aggregate( layer:='site_concours', aggregate:='count', expression:="gid", filter:=contains( geometry( @parent ), $geometry ) )
to highlight polygon features that contains my site_concours features. As you can see in the attached map, the green polygons are not coherent with the orange ones. I unsuccessfully tried different geometry predicates with categorized or rule-based rendering (note that the results returned were always the same).
Added a project to replicate.
History
#1 Updated by Giovanni Manghi over 7 years ago
- Easy fix? set to No
- Regression? set to No
#2 Updated by Giovanni Manghi over 5 years ago
- Status changed from Open to Feedback
Please check if this issue is still valid on QGIS 3.4.5 or 3.6.