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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
nicolaslemerle
Regular Visitor

Filter on the last date result by Workplace

Hi the community 🙂

 

i have a question on a report power bi
We does security audits workplaces


I have a table with information workplace/date and result Audit, if need i have too the list complety workplaces

nicolaslemerle_0-1678099892418.png

 

on my power bi i have a map to site and i would display the last result by workplace, i have used the card for display the result

nicolaslemerle_1-1678099903499.png

 

i can't found (between M-query or Dax-Query) the solution for that 

 

can you help me ? 

thanks 

1 ACCEPTED SOLUTION
MAwwad
Solution Sage
Solution Sage

 

Yes, I can help you with that.

To display the last result by workplace in Power BI, you can use the following DAX formula:

 

 
Last Result = VAR MaxDate = MAX('Table'[Date]) RETURN CALCULATE(MAX('Table'[Result]), FILTER('Table', 'Table'[Date] = MaxDate))
 

Replace 'Table' with the name of your table and 'Date' and 'Result' with the names of your columns for date and result, respectively. This formula will calculate the maximum date for each workplace and then return the result for that date.

You can then use this DAX formula in a table or visual to display the last result by workplace. For example, you can create a table with the workplace name and the last result using the above formula.

View solution in original post

2 REPLIES 2
MAwwad
Solution Sage
Solution Sage

 

Yes, I can help you with that.

To display the last result by workplace in Power BI, you can use the following DAX formula:

 

 
Last Result = VAR MaxDate = MAX('Table'[Date]) RETURN CALCULATE(MAX('Table'[Result]), FILTER('Table', 'Table'[Date] = MaxDate))
 

Replace 'Table' with the name of your table and 'Date' and 'Result' with the names of your columns for date and result, respectively. This formula will calculate the maximum date for each workplace and then return the result for that date.

You can then use this DAX formula in a table or visual to display the last result by workplace. For example, you can create a table with the workplace name and the last result using the above formula.

Thanks for your speedy answer.

I tried, it work so thank for that too 🙂

 

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.