Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Syndicate_Admin
Administrator
Administrator

Duda with chart based on display table

Good morning

I'm new to this forum and relatively also with PowerBI.

I have some data in excel of this type that obeys a survey:

cgs78_0-1732606595890.png

I need to create a report with a filter by country, a table, and a graph.

In the visualization table I must show for each city and district the mode, that is, for Ciudad_1 and Distrito_11 0 must come out Unsatisfactory, for Ciudad_1 and District _12 when there is a "tie" between 0 Unsatisfactory and 1 Improvable, 0 must come out which is the one with the lowest score between 0 and 1, and so for the others.

The chart should show the same as the display table, i.e., it should be based on the calculated mode measure and not on the data in excel. But I haven't managed to get the graph to show the same thing from the table, it's showing what's in the excel.

The "Score by City District" table correctly reflects the points fashion for each city and district.

But the graph "Evolution of the score by district and city" shows the values of the excel and not what the table Score by district city shows.

I think it's because the table is at the City-District level, while the graph is at the total level, but I don't know how to put the graph at the City-District level as well.

cgs78_1-1732606765956.png

Please, could you help?

Thanks a lot

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi, @Syndicate_Admin 

Based on your information, I create a sample table:

vyohuamsft_0-1732681543390.png

You can create a new measure, try the following dax expression:

MaxScorePerDistrictMeasure = 
CALCULATE(
    MIN('Table'[PUNTOS]),
    ALLEXCEPT('Table', 'Table'[Country], 'Table'[City], 'Table'[District])
)

 Then create visuals and put fields in them, here is my preview:

vyohuamsft_1-1732681856019.png

 

How to Get Your Question Answered Quickly

Best Regards

Yongkang Hua

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
Syndicate_Admin
Administrator
Administrator

Thank you for the help, it helped me to solve it!

Anonymous
Not applicable

Hi, @Syndicate_Admin 

Based on your information, I create a sample table:

vyohuamsft_0-1732681543390.png

You can create a new measure, try the following dax expression:

MaxScorePerDistrictMeasure = 
CALCULATE(
    MIN('Table'[PUNTOS]),
    ALLEXCEPT('Table', 'Table'[Country], 'Table'[City], 'Table'[District])
)

 Then create visuals and put fields in them, here is my preview:

vyohuamsft_1-1732681856019.png

 

How to Get Your Question Answered Quickly

Best Regards

Yongkang Hua

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.