cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
TravisGlanzer
Frequent Visitor

Number of Days in YTD through End of Last Monday

I am trying to get an quantity per day average in Power BI.  I used the following formula to calulate the number of days in each month:  

Number of days in month = DATEDIFF( EOMONTH(max('DateTable'[FiscalDate]),-1),EOMONTH(max('DateTable'[FiscalDate]), 0), DAY)

 

The per month YTD Total Average is correct but the formula is only giving me 31 days for the total when I need it to report 90 day total when selecting these three months

 

TravisGlanzer_0-1619551496066.png

 

1 ACCEPTED SOLUTION
jthomson
Solution Sage
Solution Sage

Change the first max to min and it should work?

View solution in original post

1 REPLY 1
jthomson
Solution Sage
Solution Sage

Change the first max to min and it should work?

View solution in original post

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

November Power BI Update 768x460.png

Check it Out!

Click here to read more about the November 2021 Updates!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.