Populate a dashboard bar chart based on an Enumeration field

0
Hi all, Is there a straightforward way to populate a dashboard bar chart based on an enumeration field to show values per status? Looking at it simplistically could I use an OQL statement that groups by the enumeration and counts the number of records for each value? I understand that I need a non-persistent table in my Domain model to store this information but how do I get this to run and then to collect and (temporarily) store this information in a list or an array in a microflow so a chart displays this? Any help would be much appreciated! Thanks!
asked
2 answers
0

Did you follow the documentation here: https://docs.mendix.com/refguide/chart-widgets#1-introduction ?

Basicly create a microflow where you create the series and datapoint (and you could use OQL to retrieve and calculate those) and store the result in the non persistent object which you pass to the widget.

Regards,

Ronald

 

answered
0

Hi Ronald,

Thanks for your info – yes I followed the info there before but then managed to get it work. After much debugging found that we had different column names as the alias values in the OQL compared to the non-persistent domain object – once those were matched it worked. 

I didn’t spot this being a necessity anywhere on the documentation but it obviously makes sense that it is needed!

answered