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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Anonymous
Not applicable

Calculate the total average days

Hello community!

 

I am stumped. So I am trying to do a "conversion" rate based on a start date from one table and a start date from another table. These two tables do not have a direct relationship, however, they are both connected to a main table through an ID. The main table includes the slicer # and the main table ID #. I am using a DAX where I pull the minimum date value based on the start date of each table, then I am using a datediff between those two minimum values.

 

What I need is for the sum of those conversion days for all of the main table #s and then I will divide that number by the count of main table IDs. 

 

Here's an example. Instead of it showing -254 I need it to total eveything in that table in order for me to divide it by the count. Hopefully this wasn't too confusing, Thanks!

 

dakpc_0-1681477826236.png

 

                    

 

1 ACCEPTED SOLUTION
tamerj1
Super User
Super User

Hi @Anonymous 

please try

Conversation Date (days/ID) =
AVERAGEX (
VALUES ( 'Main Table'[Main Table ID] ),
CALCULATE (
DATEDIFF ( MIN ( Table1[StartDate] ), MIN ( Table2[StartDate] ), DAY )
)
)

View solution in original post

2 REPLIES 2
tamerj1
Super User
Super User

Hi @Anonymous 

please try

Conversation Date (days/ID) =
AVERAGEX (
VALUES ( 'Main Table'[Main Table ID] ),
CALCULATE (
DATEDIFF ( MIN ( Table1[StartDate] ), MIN ( Table2[StartDate] ), DAY )
)
)

Anonymous
Not applicable

Wow I was overthinking this, LOL! Works perfectly. Thank you!

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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.