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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
lnjwilliamson86
Frequent Visitor

YTD Function Help

Hi, 

 

I am trying to perform a simple TOTALYTD function and have used to add up the number of applications recevied in a fiscal year. 

I added a column with the formula :

 

FYTD Leak Remission Applications Approved = TOTALYTD(SUM(Datasheet[1. Leak remission applications approved]),'Date'[Date],"06/30")

 

The date comes from a date table that i have added and populated useding the CALENDARAUTO function.

 

The forumla is not returning the cummulative total and is returing the individual values. Ultimately I want to graph the YTD on a line graph

 

I am wondering what I am missing as I have searched arounf the forums and it appears Im implemeting the formula correctly. 

 

Thanks. 

3 ACCEPTED SOLUTIONS
Ashish_Mathur
Super User
Super User

Hi,

 

Ensure that the date you drag from into your visual is from the Date Table.  Also does this work?

 

=CALCULATE(SUM(Datasheet[1. Leak remission applications approved]),DATESYTD('Date'[Date],"6/30"))

Does it work if you change the input to "30/6"?


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

View solution in original post

did you try @Ashish_Mathur suggestion about making sure you use the date field from your date table on the axis of your visual?


To learn more about DAX visit : aka.ms/practicalDAX

Proud to be a Datanaut!

View solution in original post

Thanks @Ashish_Mathur and @Phil_Seamark

 

Using the date column made my visual work perfectly!

 

 

 

View solution in original post

5 REPLIES 5
Phil_Seamark
Microsoft Employee
Microsoft Employee

Hi @lnjwilliamson86

 

Your code works fine for me.  Have you created it as a calculated measure and do you have a relationship between your Datasheet table and your Date table?

 


To learn more about DAX visit : aka.ms/practicalDAX

Proud to be a Datanaut!

Hi @Phil_Seamark

 

Thank you for replying so quickly!

 

I have a many to one with a single cross filter direction relationship between my datasheet table and date table.

 

I created it as a new column and i halso tried as a new meaure and neither seems to be working.

did you try @Ashish_Mathur suggestion about making sure you use the date field from your date table on the axis of your visual?


To learn more about DAX visit : aka.ms/practicalDAX

Proud to be a Datanaut!

Ashish_Mathur
Super User
Super User

Hi,

 

Ensure that the date you drag from into your visual is from the Date Table.  Also does this work?

 

=CALCULATE(SUM(Datasheet[1. Leak remission applications approved]),DATESYTD('Date'[Date],"6/30"))

Does it work if you change the input to "30/6"?


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Thanks @Ashish_Mathur and @Phil_Seamark

 

Using the date column made my visual work perfectly!

 

 

 

Helpful resources

Announcements
July 2024 Power BI Update

Power BI Monthly Update - July 2024

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

July Newsletter

Fabric Community Update - July 2024

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