Get certified for free when you join Fabric Data Days 2026 and dive into Fabric, Power BI, SQL, AI, and other essential data skills.
Join nowData Days is here! Join us now for 60+ days of learning, challenges, and connection. Learn more
Hi all, I would like created a DAX measure to group users into multiple age ranges, it works well in table form.
But I get an error when using it in other types of visualizations (eg. pie charts / bar charts).
Any pointers are greatly appreciated 😁
= = =
Here are my tables / data :
Thank you!
Solved! Go to Solution.
Hello @holywasabi
please check if this accomodate your need.
I am not sure what kind of error did you get but if it works in table form, it should work as well in other visual
Apart from the error, please check these :
1. Created calculated column for 'Income (Grouped)'
2. Since you want to create pie chart with 'Income Range' as separator/legend, then you need to make a measure to calculate it. Create measure in 'Supporting' Table with following DAX for calculating number of row that has exact same value in 'Income (Grouped)' and 'Income Range'.
3. Plot in pie chart, 'Income Range' as legend and the previous measure (Count Customer) as Values.
After putting values in pie chart, in Visual Format, turn of legend and change Label Content (Detail Label -> Option).
Also, in your screecshot table, you only provide two kind of data, the 10k-50k and 50k-100k. The rest of categories dont show up because the value is zero.
Hope this will help you.
Thank you.
Hello @holywasabi
please check if this accomodate your need.
I am not sure what kind of error did you get but if it works in table form, it should work as well in other visual
Apart from the error, please check these :
1. Created calculated column for 'Income (Grouped)'
2. Since you want to create pie chart with 'Income Range' as separator/legend, then you need to make a measure to calculate it. Create measure in 'Supporting' Table with following DAX for calculating number of row that has exact same value in 'Income (Grouped)' and 'Income Range'.
3. Plot in pie chart, 'Income Range' as legend and the previous measure (Count Customer) as Values.
After putting values in pie chart, in Visual Format, turn of legend and change Label Content (Detail Label -> Option).
Also, in your screecshot table, you only provide two kind of data, the 10k-50k and 50k-100k. The rest of categories dont show up because the value is zero.
Hope this will help you.
Thank you.
Hello @holywasabi , remember to adhere to the decorum of the Community Forum when asking a question.
Please provide your work-in-progress Power BI Desktop file (with sensitive information removed) that covers your issue or question completely in a usable format (not as a screenshot).
https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-...
Please show the expected outcome based on the sample data you provided.
https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447...
This allows members of the Forum to assess the state of the model, report layer, relationships, and any DAX applied.
Don't miss out on Data Days, June 15 through August 7. Learn Fabric, Power BI, SQL, AI and more.
Check out the May 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 |
| User | Count |
|---|---|
| 6 | |
| 4 | |
| 3 | |
| 3 | |
| 3 |