Forum Discussion
bdehning
3 years agoPost Prodigy
Rank Measure
I have this measure Rank Product = IF ( ISINSCOPE( 'InjuryCause'[Cause Grouping]), RANKX ( CALCULATETABLE ( VALUES ( 'InjuryCause'[Cause Grouping]), ...
hnguy71
3 years agoSuper User
bdehning it would just be replaced by your sum of total gross incurred. This would be then your tiebreaker value.
[Count of Total Gross Incurred] + [Sum of Total Gross Incurred],
bdehning
3 years agoPost Prodigy
Working on it. Do cRecord and tmpRank need to be columms or can they be measures?
- bdehning3 years agoPost ProdigySecond Return says Unexprected ReturnRETURN _tmpRank,RETURN
- bdehning3 years agoPost Prodigy
Almost there but I have this
VAR _TieBreaker =IF(ISINSCOPE('InjuryCause'[Cause Grouping]),VAR _cRecord = MAX('InjuryCause'[Cause Grouping])VAR _tmpRank = COUNTROWS( FILTER(ALL('InjuryCause'), 'InjuryCause'[Cause Grouping] >= _cRecord ))RETURN _tmpRank,RETURNIF(ISINSCOPE( 'InjuryCause'[Cause Grouping]),RANKX (CALCULATETABLE (VALUES ( 'InjuryCause'[Cause Grouping]),ALLSELECTED ( 'InjuryCause'[Cause Grouping] )),[Count of Total Gross Incurred] + [Sum of Total Gross Incurred],,DESC,DENSE))It is not getting past the 2nd return as it says Unexpected Return?