Hi all!!
I am trying to create an expression depending on the value of the dimension. If the dimension is not 'SFA', the expression is the sum of the values of the dimension, but if it's 'SFA', the expression is the result of dividing two other expressions of other dimensions. Something like this:
=pick( match(KPI_M2, 'AKO', 'RPK','SFA','PSN','PSR','JTP')
,Sum({$<KPI_M2={$(='AKO')},TIPO={$(='REAL')}>} VALOR_OS)/1000
,Sum({$<KPI_M2={$(='RPK')},TIPO={$(='REAL')}>} VALOR_OS)/1000
,(Sum({$<KPI_M2={$(='RPK')},TIPO={$(='REAL')}>} VALOR_OS)/Sum({$<KPI_M2={$(='AKO')},TIPO={$(='REAL')}>} VALOR_OS))*100
,Sum({$<KPI_M2={$(='PSN')},TIPO={$(='REAL')}>} VALOR_OS)/1000
,Sum({$<KPI_M2={$(='PSR')},TIPO={$(='REAL')}>} VALOR_OS)
,Sum({$<KPI_M2={$(='JTP')},TIPO={$(='REAL')}>} VALOR_OS)
)
Thank you for your help!!.
Regards!