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
Anonymous
Not applicable

How to count amount of days between 2 dates

Hey all,

 

I have a table like this

Date occuredDate Reported
1/1/202/1/20
3/2/203/2/20
5/7/2015/7/20

 

How would I write DAX to count the days from occured to reported and then provide the average. Also counting same day reported as "1" not "0".

 

Thanks,

J

1 ACCEPTED SOLUTION

@Anonymous , Check this file, on 2nd page there is visual having working day diff

https://www.dropbox.com/s/y47ah38sr157l7t/Order_delivery_date_diff.pbix?dl=0

 

Just make sure weekday is taken correctly

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

3 REPLIES 3
amitchandak
Super User
Super User

@Anonymous , You can create a new column like

New column =datediff([Date occured],[Date Reported],Day)+1

 

And take Average of this

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube
Anonymous
Not applicable

@amitchandak 

 

Thanks that worked great! Is there a way to also count only Mon - Fri?

 

J

@Anonymous , Check this file, on 2nd page there is visual having working day diff

https://www.dropbox.com/s/y47ah38sr157l7t/Order_delivery_date_diff.pbix?dl=0

 

Just make sure weekday is taken correctly

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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