Forum Discussion
TOTALYTD Returning BLANK
I am having some trouble with a simple TOTALYTD formula. I am trying to count the total projects YTD. My table has a relation from the Submitted date of the project and a Date table. I have tried most of the other examples from the forum with no luck.
Proposals YTD = COUNT('Professional Services Quotes'[Project Name])
Returns the total count of all projects
Proposals YTD = TOTALYTD(COUNT('Professional Services Quotes'[Project Name]),Dates[Date].[Date])
Returns BLANK
Proposals YTD = TOTALYTD(COUNT('Professional Services Quotes'[Project Name]),Dates[Date].[Date], filter('Professional Services Quotes','Professional Services Quotes'[Submitted Date] < NOW()))
Returns BLANK
I am also trying to do a comparison to Last Year to date with no luck as well. I am guessing the fix for the YTD will solve my problem with the YTD LY calculation. If anyone has any ideas it would greatly appriciate it.
Thanks
With the TOTALYTD or DATESYTD functions, year-to-date is defined relative to the maximum value of Dates[Date] in the filter context.
If the maximum value of Dates[Date] is in 2025 and you haven't applied any Date filters, and your 'Professional Services Quotes' table doesn't extend to 2025, then TOTALYTD changes the filter on Dates[Date] to the range 1/1/2025-31/12/2025 (assuming you have the complete 2025 calendar year in Dates), which would give you a BLANK result.
Normally these functions are used in the context of days or months within a single year, and will return a YTD value within that year.
11 Replies
- Sean
Community Champion
Since you have a Date/Calendar table - DO NOT use the .[Date] notation - reference only Dates[Date] :smileyhappy: