rust_query

Function aggregate

Source
pub fn aggregate<'outer, S, F, R>(f: F) -> R
where F: for<'a> FnOnce(&'a mut Aggregate<'outer, 'a, S>) -> R,
Expand description

Perform an aggregate that returns a single result for each of the current rows.

You can filter the rows in the aggregate based on values from the outer query. That is the only way to get a different aggregate for each outer row.