Hi I have denormalized the data to be flat in elasticsearch.
e.g.
{childId: 123, childAmount: 3.4, parentId: 1, parentAmount: 5.6}
{childId: 234, childAmount: 4.4, parentId: 1, parentAmount: 5.6}
{childId: 345, childAmount: 5.4, parentId: 2, parentAmount: 1.2}
See there are 3 children and 2 identical parent. How to calulate the sum amount of parentAmount (which should be 6.8)?
Thanks. And if possible, how to use kibana metric visual to show this data?