Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I am trying to sum the following the if condition but I am getting error in expression.
=sum(if(
(count({<[Status]={'Satisfied'}>} [Status])/Count([Status]))
-
max(target)
> 0 ,1,0
))
Do I need to use aggregate function for this?
I did go through some posts and it showed sum and if works together but it wasn't for set analysis so I am not sure
Which dimension/s are you checking this condition against?
if(
(count({<[Status]={'Satisfied'}>} [Status])/Count([Status]))
-
max(target)
> 0
Thank you for the reply Sunny.
So I have 2 tables and both of them are connected by 3 dimensions
The main table has 4 columns Region, Company, Type, Status(satisfied, negative, neutral)
The target table has the same first 3 columns and the last column is the Target
I have joined these 2 tables using the 3 common columns
Now I am trying to compare the total count of status(satisfied) and the target and then sum the total which have crossed the target. All of these aggregated by Region->Company->Type
May be this
=Sum(Aggr(
If((Count({<[Status] = {'Satisfied'}>} [Status])/Count([Status]))-Max(target)> 0, 1, 0)
, Region, Company, Type))