Pie chart data point value attribute to be a string and not decimal
0
I'm using Mendix Desktop Modeller 7.20.1. I'm trying to use Pie Chart widget. I have a list of objects which store records with an attribute "Status" which has different values such as "Assigned", "Fix initiated", "Resolved". I have to create a pie chart to represent status-wise distribution of records(say, 10% records have status as "Assigned", 90% records have status as "Resolved") . But as it seems, the data point value must be a decimal which is not the case here as "Status" is a string. Please provide some insight over this. Thanks in advance.
asked
Niraj Jajoo
2 answers
0
Hi Niraj,
Maybe you can retrieve the different lists based on the "Status" and do a count on them. Then create a Decimal variable and fill it with the countresult. now you have a Decimal value which you can use for the pie chart.
Kind regards,
Ritchie
answered
Ritchie Slangen
0
I think it's fastest/easiest to retrieve the data with a microflow and create a new list of data points. Entity could be like this:
Widget setup:
And the microflow could be something like this, which returns the list of newly created data points: