Forum Discussion
Anonymous
3 years agoNot applicable
Unpivot Column with Different Calculation Applied
Hi there, I am trying to unpivot data matrix using pwoer query but the data calculation is not only using summraize but also average since the value have different value format, iie. absolute num...
- 3 years ago
Hi Anonymous
Please tryTotal Target (Switch) = IF ( CONTAINSSTRING ( MAX ( 'Table'[Indicator] ), "%" ), AVERAGEX ( VALUES ( 'Date'[YearMonth] ), [Total Target] ), SUMX ( VALUES ( 'Date'[YearMonth] ), [Total Target] ) )Same for total actual
tamerj1
3 years agoCommunity Champion
Hi Anonymous
Please try
Total Target (Switch) =
IF (
CONTAINSSTRING ( MAX ( 'Table'[Indicator] ), "%" ),
AVERAGEX ( VALUES ( 'Date'[YearMonth] ), [Total Target] ),
SUMX ( VALUES ( 'Date'[YearMonth] ), [Total Target] )
)
Same for total actual