Create Pie Chart for Agg of 2 fields

(Chen Ben Ezra) #1

Hi ,

My index contain the following fields:

I want my Pie chart will contain the sum of each one of the fields , that means the pie chart will be separate for 2 parts (to the sum of rb_commits and the sum of git_commits).
In the aggregation part at the Chart , I can choose only 1 Field .
How can I do it in Kibana ?


(Spencer Alger) #2

The only way to create the sum of these fields (without creating a new field) is to use a scripted field. This field could just include the sum of both fields:

doc['rb_commit'].value + doc['git_commit'].value

(Chen Ben Ezra) #3

Hi ,
I created the scripted field , it contain the correct sum of both of fields.
But how can I create my Pie Chart that will be separate for sum of all rb_commit and sum of git_commit ?
For example:

The red part is rb_commit and the green part is git_commit,
Thanks :slight_smile:


(Chen Ben Ezra) #4

Hi ,
Can you help me with that issue ?
Thanks :slight_smile:


(system) #5