Skip to main content
The sum aggregation computes the sum of a field.
Expected Response
See the Tantivy documentation for all available options.

SQL Sum Syntax

SQL’s SUM syntax is supported in beta. To enable it, first run
With this feature enabled, the following query is equivalent to the above and is executed in the same way.
SQL
By default, SUM ignores null values. Use COALESCE to include them in the final sum:
SQL