My except function isn't working

I have Issues with 3 labels.
I’m trying to combine all issues with "strategy-workaround’ and ‘workaround’ in one aggregate and
the other column is (none) and "Team#TEST’

The problem is that some of the issues with ‘strategy-workaround’ in label also have ‘Team#TEST’. I would like to exclude these from the total for the (none) column. Here is the calculated member I am using for the (none) total.

Aggregate(
Except([Label].Members,
{[Label].[strategy-workaround],[Label].[workaround]}))

I’m still getting issues included in this total with ‘strategy-workaround’ and ‘Team#TEST’.

Any suggestion"

Hi,

The multiple value dimensions work in a specific way with the except condition. Your approach is not working as expected because it generates the set of labels and then applies it to measures. If an issue has any other label than the “workaround,” it generates a count with the other label (although you excluded the workaround labels).

In your use case, there seem to be two different conditions for the “none” counting. First, the issues with labels of none and Team#TEST must be counted. The second is that issue must not be counted whenever any of the “workaround” labels are present.

The safest solution to this use case is to implement a custom measure explicitly filtering issues by this condition:

NonZero(Count(
  Filter(Descendants([Issue].CurrentMember,[Issue].[Issue]),
    not CoalesceEmpty([Measures].[Issue labels],"") Matches ".*workaround.*"
    AND
    ([Measures].[Issues created],
    [Label].[none and test])>0
  )
))

Here the “none and test” is the following aggregate member in the label dimension:

Aggregate(
  {
  [Label].[(none)],
  [Label].[Team#TEST]
  }
)

Kindly,
Janis, eazyBI support