Sum Aggregation with elasticsearch data source shows only one value


I’m trying to create a single stat panel that displays a sum of the values of a field for the selected time range.
The data source is elastic, 6.0+ version.
The problem I’m having is that it only shows one value of the field and not the sum. Depending on the order by the value changes, but it never shows the sum.
The configuration is:
Metric: Sum --> field_name
Group By: Terms --> field name


Found the answer, I had to chose the Column “Sum” in the Values section of the options tab