Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!
Hi all,
I am trying to calculate the number of Tickets last year for the same tinme period as this year.
TCTD 2020 should count 01/01/20 and Today - 1 Year
Below is what I have written but i am not getting the count i'm expecting.
Solved! Go to Solution.
Try to create measures like this:
this_year = TOTALYTD(COUNT('Change Request'[Number])+COUNT(Incidents[Number])+COUNT(Problems[number]),'Table'[Date])
last_year = CALCULATE([this_year],SAMEPERIODLASTYEAR('Table'[Date]))
Try to create measures like this:
this_year = TOTALYTD(COUNT('Change Request'[Number])+COUNT(Incidents[Number])+COUNT(Problems[number]),'Table'[Date])
last_year = CALCULATE([this_year],SAMEPERIODLASTYEAR('Table'[Date]))
@MC007 , with help from the date table you get a year behind the measure
Year behind Sales = CALCULATE(count('Incidents'[Number]),dateadd('Date'[Date],-1,Year))
or
Year behind Sales = CALCULATE(count('Incidents'[Number]),SAMEPERIODLASTYEAR('Date'[Date]))
or
1 day 1 year behind today
LYTD =
var _min = date(year(today())-1,1,1)
return
CALCULATE(count('Incidents'[Number]), FILTER(ALL('Date'),'Date'[Date] = _min))
User | Count |
---|---|
124 | |
108 | |
99 | |
62 | |
62 |
User | Count |
---|---|
137 | |
116 | |
102 | |
71 | |
61 |