[QGIS-Developer] Filtering features in a layer by a report group

Tim Sutton tim at kartoza.com
Tue Aug 6 23:22:40 PDT 2019


Hi All

I am trying to create a section in my report (not layout) which iterates over my plant types lookup table and applies a filter to my vegetation points layer based on the plant type ID.

Ideally I should set my filter of my vegetation layer based on the atlas feature id like this:  "plant_type_id" = attribute(@atlas_feature,id)

Instead I tried to make a rule using the same above expression so that symbols are blank for non matching plant features.

However in my report group, ‘Controlled by report’ is greyed out for my map and so when rendering the report the map comes out as a single blank copy instead of one per plant type. 

I suspect this is because report wants to have geometries to zoom to for each record. Other than adding a fake geometry column to my plant type lookup table, is there any way to get reporting to control my map by report when the reporting layer is a non-spatial table?


Side note: QGIS layer filtering is a "poor relation” it is one of the few places in QGIS where a non standard expression editor is used. The other major one was the raster calculator but now at least we have the raster calculator processing algorithm.

BTW using 3.8 on macOS here.


Thanks!

Regards

Tim
—









Tim Sutton

Co-founder: Kartoza
Ex Project chair: QGIS.org

Visit http://kartoza.com <http://kartoza.com/> to find out about open source:

Desktop GIS programming services
Geospatial web development
GIS Training
Consulting Services

Skype: timlinux 
IRC: timlinux on #qgis at freenode.net

I'd love to connect. Here's my calendar link <https://calendly.com/timlinux> to make finding time easy.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20190807/249bcc65/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: KartozaNewLogoThumbnail.jpg
Type: image/jpeg
Size: 6122 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20190807/249bcc65/attachment-0001.jpg>


More information about the QGIS-Developer mailing list