Forum Discussion
Comparing measures with wrong result
Hello All,
I am trying something very simple but I haven't been able to figure out why is not working:
I am using an IF function to compare 2 measures:
Measure 2 is a constant equal to 1.
Measure is a calculate function that sums the number of rows of a table
IF function ALWAYS returns true, even when they are no equal. I am usign cards to check the values:
I appreciate any guidance. I am going nuts
Regards
jsebago are you adding compare as a column or a measure? it should be a measure.
3 Replies
- AnonymousNot applicable
Hi jsebago ,
What about trying the strict equality operator or converting to text and then comparing?
Compare 1 = IF([Measure]==[Measure 2],"True","False")Compare 2 = IF(EXACT([Measure],[Measure 2]),"True","False")Reconfirm that [Measure] and [Measure 2] are measures (icons for measure).
If the problem remains unresolved, please consider posting a sample pbix file.How to provide sample data in the Power BI Forum - Microsoft Fabric Community
Best Regards,
Gao
Community Support TeamIf there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!How to get your questions answered quickly -- How to provide sample data in the Power BI Forum