Hello @KimC,
Thank You for posting your query onto the Forum.
There’re two reasons why it’s not yielding the results as per the expectations.
1). Date Context Ignored Inside The Multi-Row Card Visual When Working With Time Intelligence Functions -
When results are evaluated in the form of time intelligence functions i.e., in this case by using “DATEADD()” as well as “DATESYTD()” functions, you need to provide date context either inside the visual or in the form of external filter context.
The reason why it’s yielding the results in the form of table visual is because inside the visual itself you’ve provided the context in the form of dates and therefore, it evaluates the results accordingly. But in the case of card visual, there’s nowhere presence of date context and therefore, it’s unable to pass the context of date and hence it gives the results as “BLANKS”.
2). Filter Context Coming From The Filter Pane Inside The Table Visual -
Secondly, inside your table visual, you’re supplying external filter context in the form of Filter Pane by putting the conditions as - “Month Name <> Jul”, “Qtr = Q1, Q2 and Q3” and “Year = 2021 or 2022” but the same cannot be passed onto the Multi-Row Card visual since that will be applicable to entire card.
Based on the above limitations stated, you’ll be required to create the additional measures with the necessary context provided in them, as you’ve provided inside your table visual, in order to put them inside your Multi-Row Card visual. Below are the measures alongwith the screenshot of the final results provided for the reference -
Count YTD - Harsh =
CALCULATE( [Count Total] ,
Dates[FiscalYearOffset] = 0 ,
Dates[Qtr] IN { "Q1" , "Q2" , "Q3" } ,
Dates[Month Name] <> "Jul" )
Count Prior YTD - Harsh =
CALCULATE( [Count Total] ,
Dates[FiscalYearOffset] = -1 ,
Dates[Qtr] IN { "Q1" , "Q2" , "Q3" } ,
Dates[Month Name] <> "Jul" )
I’m also attaching the working of the PBIX file for the reference purposes.
Hoping you find this useful and meets your requirements that you’ve been looking for.
Thanks and Warm Regards,
Harsh
Test DAX Problem - Harsh.pbix (97.2 KB)