Forum Discussion
datanau001
Helper III
5 years agoGet count per timestamp for each ID
Hello all, I'm trying to a new column called "Time Stamp Incidence" to show the incidence of timestamps per each ID(SR_Number). See the below screenshot: 1st ID on the new column would be showi...
- 5 years ago
Yes datanau001 - one of the few times a column is better than a slicer. Slight tweak to my measure:
Item Count = VAR varCurrentValue = 'Table'[Item] VAR Result = CALCULATE( COUNTROWS('Table'), 'Table'[Item] = varCurrentValue, REMOVEFILTERS('Table') ) RETURN COALESCE(Result,0)Strictly speaking the COALESCE() at the end isn't necessary as you'd never have a blank like this in a column, but I am just in the habit of using it with any measure that has COUNTROWS() so I get a true 0 vs <BLANK>
You could just use "Result" at the end after the RETURN statement.
PhilipTreacy
Super User
5 years agoBest to say initially that you want this for a slicer so you get the right answer straight away.
regards
Phil