cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
cmccully Helper I
Helper I

Days Between Current Date and End of Current Year

Hello

 

I am trying to find the difference in days between the current date today() and the end of the current year. All the functions I am finding want a table field as an argument. But I am not concerned with my dataset for this purpose.

 

As an example, today is 02/19/2020. there are 316 days until the end of the year. I want a measure that will show 316 today, 315 tomorrow, etc. Then roll over to 365 on january 1st 2021.

Thank you for your help!

1 ACCEPTED SOLUTION

Accepted Solutions
cstaulbee Resolver III
Resolver III

Re: Days Between Current Date and End of Current Year

Try:

Measure = 
DATEDIFF( TODAY(), DATE(YEAR(TODAY()), 12, 31), DAY)

View solution in original post

3 REPLIES 3
cstaulbee Resolver III
Resolver III

Re: Days Between Current Date and End of Current Year

Try:

Measure = 
DATEDIFF( TODAY(), DATE(YEAR(TODAY()), 12, 31), DAY)

View solution in original post

Anonymous
Not applicable

Re: Days Between Current Date and End of Current Year

Hi @cmccully 

Measure = 
DATEDIFF( TODAY(), DATE(YEAR(TODAY()), 12, 31), DAY)

Incase you want it for your date column.

Measure = 
DATEDIFF( min(Table[Date]), DATE(YEAR(min(Table[Date])), 12, 31), DAY)

 

Thanks & regards,
Pravin Wattamwar
www.linkedin.com/in/pravin-p-wattamwar

If I resolve your problem Mark it as a solution and give kudos.

 

cmccully Helper I
Helper I

Re: Days Between Current Date and End of Current Year

Thank you, this works perfectly!

Helpful resources

Announcements
Announcing the New Spanish Forum

Announcing the New Spanish Forum

Do you need help in Spanish? Check out our new Spanish community section.

April 2020 Community Highlights

April 2020 Community Highlights

Info on our Super Users, MBAS content and badges, and updates to our support articles. - Read the full Community Highlights.

MBAS Gallery 2020

MBAS Gallery 2020

Watch Microsoft Business Applications Summit sessions on-demand.