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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
can5539
Frequent Visitor

Can't show Image URL in matrix on recent date.

powerbi ask.png

 I need to show status(image URL GREEN/ORANGE/RED) of transformer at every location on recent date that workers do oil dielectric test but dashboard still shows wrong image URL.

 

For example

     DATE                           Status

  1/1/2020         Red(should change oil)

  2/1/2020         orange(should filter oil)

  3/1/2020         Green(good condition)

In Matrix

                           No.

                           Substation No.

 

Location            Green

1 ACCEPTED SOLUTION

@can5539 , Try one of the 2

Measure =
var _max = calculate(lastedate(Table[Date]))
return
calculat(max(Table[url]), filter(Table,Table[Date]=_max))

or

Measure =
var _max = maxx(allselected(Table),Table[Date])
return
calculat(max(Table[url]), filter(Table,Table[Date]=_max))

View solution in original post

6 REPLIES 6
amitchandak
Super User
Super User

@can5539 , you can create a measure to return URL and at recent date only and change is the type to URL

 

Measure = calculat(max(Table[url]), filter(Table[Date]=lastedate(Table[Date]))

@amitchandak It shows error "The argument is passed too little to the FILTER function. The minimum number of arguments for this function is 2."

I can't do your recommendation.

powerbi ask2.png

@can5539 , Try one of the 2

Measure =
var _max = calculate(lastedate(Table[Date]))
return
calculat(max(Table[url]), filter(Table,Table[Date]=_max))

or

Measure =
var _max = maxx(allselected(Table),Table[Date])
return
calculat(max(Table[url]), filter(Table,Table[Date]=_max))

@amitchandak I try out your solution. It works!Thank you for your help.

@can5539 , Try like

Measure = calculat(max(Table[url]), filter(Table,Table[Date]=lastedate(Table[Date]))

@amitchandak It shows red image in all cells. It still shows wrong data.

powerbi ask3.png

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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