Forum Discussion
AmberJane
Helper III
4 years ago% Difference from two filtered fields on a column
Hi Team,
I am these tickets that go through different states that you can see in the screenshot below. I want to show the % of tickets that have been closed. I think the way to do this is to create a column or measure (not sure) that takes the # of tickets and divides it by the # of tickets in the state of closed. In this specific screenshot there is 17 tickets total and 5 have been closed so I want it to show 29%.
Any help is appreciated!
You can do that with a measure like this.
Closed % = VAR _Closed = CALCULATE ( [Work Items Count], KEEPFILTERS ( YourTable[State] = "Closed" ) ) VAR _All = CALCULATE ( [Work Items Count], REMOVEFILTERS ( YourTable[State] ) ) RETURN DIVIDE ( _Closed, _All )
2 Replies
- jdbuchanan71
Super User
You can do that with a measure like this.
Closed % = VAR _Closed = CALCULATE ( [Work Items Count], KEEPFILTERS ( YourTable[State] = "Closed" ) ) VAR _All = CALCULATE ( [Work Items Count], REMOVEFILTERS ( YourTable[State] ) ) RETURN DIVIDE ( _Closed, _All )- AmberJane
Helper III
That did the trick! I feel like there should be an easier way to accomplish this but thank you for the measure details. It has me moving forward.