[Qgis-developer] Aggregates within expression engine

Neumann, Andreas a.neumann at carto.net
Wed Mar 16 01:32:29 PDT 2016


Hi, 

Yes, the use cases that triggered this project are: 

 	* print composer
 	* atlas printing
 	* tables and forms (virtual fields): aggregates on related tables
(e.g. show all owners of a parcel, or the count or mean age of all trees
in a parcel)

Who knows, it could even be useful in labelling, symbology, etc. - e.g.
using the above example with the trees: color the parcels based on the
mean age of all trees in the parcels. 

I guess there are many more use cases we don't even think about
currently. 

Andreas 

On 2016-03-16 09:21, Nyall Dawson wrote:

> On 16 March 2016 at 19:15, Hugo Mercier <hugo.mercier at oslandia.com> wrote: 
> 
>> Hi,
>> 
>> Just for me to understand: why not considering improving a bit the
>> virtual layers ?
>> 
>> There is already a support for user defined aggregate functions. Caching
>> of the computed aggregate is already done by the engine (I guess). And
>> we could add some functions to restrict the query to the selected
>> features of a layer or deal with relations ...
>> 
>> And using something like the "query builder" found in db manager (and
>> inspired by mapinfo), it may ease to deal with the SQL syntax ...
> 
> I think the use case is quite different. Having aggregates in
> expressions is useful for things like embedding the values in
> composers and atlas prints, or in data defined overrides.
> 
> Nyall

  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20160316/b7b1ed4e/attachment.html>


More information about the Qgis-developer mailing list