Trying to create a pie chart of "Items by it's price".
PFA for the data that I have inserted and the chart.
Issue is that the value is not showing properly.It's showing the total value of three items for the individual item.
Please help me out...
The problem here is that you're using an array, which is sometimes handled unexpectedly in Kibana. In reality here you've actually only got one document, not three.
So, when you ask, "What's the sum of Price for Jacket?", you're not asking "What's the sum of Price for all sub-items labeled Jacket?", you're actually asking "What's the sum of Price for all documents that have a Jacket?", to which the answer actually is 1000, because it sums up all of the subarray Prices.
I'm not sure if that makes too much sense, but if you want it to work the way you're expecting, you're going to have to have a separate index which has one document per line item.
This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.