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
Dunner2020
Post Prodigy
Post Prodigy

DATESYTD for regulatory year

Hi there,

 

I am trying to use DATESYTD() in the regulatory year context (The regulatory year starts from 1st April and ends on 31st March). I changed the calculation based on some existing threads to the following:

 

YTD sum = CALCULATE([Measure], DATESYTD(Dates[Date],"31/3"))

 However, it returns the blank. I assume that its not working as I have already checked [Measure] and it produces the value if 

i did not use with DATESYTD(). Could anyone help me where am I making the mistake?

1 ACCEPTED SOLUTION
selimovd
Super User
Super User

Hey @Dunner2020 ,

 

depending on your local settings the date could be false. Try maybe to change the end of year date to "3/31".

What always works is to use a regular date, the year will be ignored anyways. So try the following:

YTD sum = CALCULATE( [Measure], DATESYTD( Dates[Date], "2020-03-31" ) )

 

If you need any help please let me know.
If I answered your question I would be happy if you could mark my post as a solution ✔️ and give it a thumbs up 👍
 
Best regards
Denis
 

View solution in original post

1 REPLY 1
selimovd
Super User
Super User

Hey @Dunner2020 ,

 

depending on your local settings the date could be false. Try maybe to change the end of year date to "3/31".

What always works is to use a regular date, the year will be ignored anyways. So try the following:

YTD sum = CALCULATE( [Measure], DATESYTD( Dates[Date], "2020-03-31" ) )

 

If you need any help please let me know.
If I answered your question I would be happy if you could mark my post as a solution ✔️ and give it a thumbs up 👍
 
Best regards
Denis
 

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.