Forum Discussion
Identify and Show Duplicate Records Using Nested IF or SWITCH statements
- Anonymous5 years ago
I appreciate all your help. The "If" part of the statement did not like the text: I got this error message. So I used 0,1 instead.
I realize I forgot to mention a specific scenario - is it possible to have this type of result also be false?
Thank you so much for the response. I feel like this may work. However, I don't know what DAX you would use to create the_countLoginId to correspond with the parent name. My attempts to produce that measure failed. I apologize if this is simplistic DAX (I am very new).
Cheers,
TH
Sorry for my mistake, the correct formula should be as follows
_result =
VAR _countId =
CALCULATE (
DISTINCTCOUNT ( Data[Login] ),
ALLEXCEPT ( 'Data', Data[Parent name] )
)
VAR _if =
IF ( _countId = 1, "FALSE", "True" )
RETURN
_if
The other formula is just to explain the intermediate process, its formula is as follows
_countLoginId =
CALCULATE (
DISTINCTCOUNT ( Data[Login] ),
ALLEXCEPT ( 'Data', Data[Parent name] )
)
Thank you for your correction.
Hope this helps.
Best Regards,
Community Support Team _ Zeon Zheng
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.