Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
Hello friends,
I thought it was simple but I must be missing something
I have a report that compares columns
In the card I want to show that:
If the number is different then the background will be red
And if the number is the same then the background will be green
This is the measure:
Solved! Go to Solution.
Hi, @netanel ;
I tested for a long time and found that your data are all very long decimals, such as 1.00002 and 1.000015, which are about equal to 1, but they are not equal, so the natural colors are always the same, because they have always been unequal, but they seem to be equal, and you need to change the source data, or round up.
if we change it.
flag =
var _a=ROUND( [Sum OpenQTY]-[Sum OpenQTY Line],6)
return IF( _a<>0 ,"#32CD32","#FF0000")
The final show:
Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi, @netanel ;
I tested for a long time and found that your data are all very long decimals, such as 1.00002 and 1.000015, which are about equal to 1, but they are not equal, so the natural colors are always the same, because they have always been unequal, but they seem to be equal, and you need to change the source data, or round up.
if we change it.
flag =
var _a=ROUND( [Sum OpenQTY]-[Sum OpenQTY Line],6)
return IF( _a<>0 ,"#32CD32","#FF0000")
The final show:
Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thanks, that was really the problem
Everything works fine now
Thanks for the quick reply!
If you choose your measure you can and enter the visualizations options you can often change the colors there. That is how I solve that kind of problems.
Is there a reason why you prefer to solve it with Dax?
Hi @ThomasWeppler
Thanks for the response,
Rule Based on one field and I need to base on two fields,
I am trying to display a difference between a column from table A and a column from table B
That is, if a card from table B is different from the card from table A, then the background is red, otherwise it is green
It is impossible to do such a thing in Filed Value
Anway thanks!
Just make a measure based on two values and use that.
Measure = if(table1[column1] <> table2[column2], 1,2)
@ThomasWeppler
This is exactly my Measure in my first Post
Thanks but @v-yalanwu-msft Find the problem and help me to solve the problem!
Hi, @netanel ;
please provide your expected result with backend logic and special examples. It is better if you can share a simplified pbix file.
Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @v-yalanwu-msft
Thanks for the response
There is a link to the PBIX file in the first message I sent
I also detailed more in the file
User | Count |
---|---|
116 | |
73 | |
62 | |
49 | |
47 |
User | Count |
---|---|
173 | |
123 | |
60 | |
59 | |
57 |