Forum Discussion
android1
8 years agoPost Patron
Count point in time
Hi,
Trying to count the number of staff who started in each Week and Active = Y. I have their start date & a column which shows the last date in the week they started. Any idea how to achieve this?
Hi android1
Try this MEASURE
MEASURE = CALCULATE ( COUNT ( TableName[Active] ), TableName[Active] = "Y" )
HI android1
In that case you can use this MEASURE.
[Measure] is the measure we created above to count the employee each week
Cumulative Count = SUMX ( FILTER ( ALLSELECTED ( TableName[Week] ), TableName[Week] <= SELECTEDVALUE ( TableName[Week] ) ), [MEASURE] )
4 Replies
- Zubair_MuhammadCommunity Champion
Hi android1
Try this MEASURE
MEASURE = CALCULATE ( COUNT ( TableName[Active] ), TableName[Active] = "Y" )
- android1Post Patron
That's great. Thank you.
I'd like to show a running total as well. So if I was looking at week 5 id like to see total number of staff with a start date in week 5 plus the total from the previous 4 weeks.
- Zubair_MuhammadCommunity Champion
HI android1
In that case you can use this MEASURE.
[Measure] is the measure we created above to count the employee each week
Cumulative Count = SUMX ( FILTER ( ALLSELECTED ( TableName[Week] ), TableName[Week] <= SELECTEDVALUE ( TableName[Week] ) ), [MEASURE] )