Forum Discussion
Anonymous
6 years agoNot applicable
How to use a dynamic string variable
Hi guys, Hope you can help me, i have this table: the data is not always sorted so, i am looking for the operator name where the id is the highest: this the following i was able to get ...
- Anonymous6 years ago
Hi Anonymous ,
Please try to create a calculated column with below formula to replace the original measure:
Column = VAR _topclient = CALCULATE ( MAX ( 'Well List'[Operator] ), FILTER ( ALL ( 'Well List' ), 'Well List'[WellID] = MAX ( 'Well List'[WellID] ) ) ) RETURN IF ( 'Well List'[Operator] = _topclient, 1, 0 )Best Regards
Rena
Anonymous
6 years agoNot applicable
Hi Anonymous ,
Thanks for your answer, i already tried that way before with the result but, i see in your example you have two "JJ", so basically how would you add the 1 value in all the JJ's in the column?
Anonymous
6 years agoNot applicable
Hi Anonymous ,
Please try to create a calculated column with below formula to replace the original measure:
Column =
VAR _topclient =
CALCULATE (
MAX ( 'Well List'[Operator] ),
FILTER (
ALL ( 'Well List' ),
'Well List'[WellID] = MAX ( 'Well List'[WellID] )
)
)
RETURN
IF ( 'Well List'[Operator] = _topclient, 1, 0 )Best Regards
Rena
- parry2k6 years agoSuper User
Anonymous I don't understand why we are all after creating the column when measure can do the job. Do we understand the difference between creating measure vs columns and how it has an impact on the model?