sum static method
Constructs a sum aggregation operation.
The field
parameter specifies the field to sum.
Example:
var query = DQ.sum('field'); // { '\$sum': '\$field' }
Implementation
static Map<String, Object?> sum(String field) {
return {'\$sum': '\$$field'};
}