Hi,
I have a question about Aggregations. I have documents with several fields:
{
field1 : A,
field2: B,
field3: C,
size: 1,
}
{
field1 : A,
field2: B2,
field3: C2,
size: 2,
}
{
field1 : Z,
field2: B3,
field3: C3,
size: 99,
}
And I need to be able to calculate aggregations for each one of those
fields, and get the sum of the sizes for each field, so for example,
aggregating by field1 should get me { A, size = 3 }, {Z, size = 99}.
Looking at the documentation for aggregations I can see how to get the sum
for a field and how to get the terms and their counts, but I need a
combination of both, what is the best way to do this?
Thanks in advance,
Jose.
--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/1deb1eb1-a5dc-40cb-8689-c5518869f40a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.