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
Joacb761
Frequent Visitor

Card visual with Average of Minimum Values per ID

Hello everyone! 

 

I'm fairly new to PowerBI and DAX and I'm stuck on this problem!

 

I have a dataset set up like this:

Row NumberClient IDMost Recent Contact or AttemptDateDays Since
1AContact5/15/202070
2AAttempt6/15/202039
3BContact7/5/2020

19

4BAttempt6/29/2020

25

 The "Days Since" column is a calculated column using Datediff between the Date column and Today().

This table is connected to another table of Employee IDs on Client IDs.

I'm hoping to create a Card Visual that displays "Average Days since last contact or attempt", which will provide the Average of "Days Since" using the most recent dates for each client ID. I'm hoping that the visual would update depending on which employee ID is selected in a filter visual.

 

I'm not sure if this is something that can be done with a measure or a calculated table, any assistance would be helpful!

 

1 ACCEPTED SOLUTION

No worries, here is the link to a video that expains how to do it:

 

https://youtu.be/HwL5W083TCo

View solution in original post

4 REPLIES 4
Icey
Community Support
Community Support

Hi @Joacb761 ,

 

Is this problem solved?


If it is solved, please always accept the replies making sense as solution to your question so that people who may have the same question can get the solution directly.


If not, please let me know.

 

 


Best Regards,
Icey

andre
Memorable Member
Memorable Member

Click on Days Since column, go to Column Tools in the Ribbon then find Summarizatin and select Average.  Now when you drag that column to either table or matrix control or a card visual, it will show you average Days Since in the whaver filter context that you have set on the page or in the visual

 

to do an average of min you need to do somethigg like this:

 

AVERAGEX(ADDCOLUMNS(values(mytable[mycol], minVal, min(othertable[somecolumn]), minVal)

Hey! I can't seem to make sense of the Dax you provided, how would I add in Minval? I'm also not sure what column in my other table I would need to include here.

No worries, here is the link to a video that expains how to do it:

 

https://youtu.be/HwL5W083TCo

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.