Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi,
I'm trying to compare two columns using clustered column chart, and want to make a filter that if I select "yes" then the visual will be filtered into a visual that shows column a more than column b.
Is it possible to use greater than as a result in the if statement?
For example,
Activity has planned duration and actual duration.
And If I select yes in slicer then the visual will display the actual duration value that exceeds the planned duration, and if I select no it will display the actual duration value which is less than equal to the planned duration.
Appreciate your help.
Thank you.
Solved! Go to Solution.
The big question here is if you can do it as a column or if you need a measure.
If you can do it as a column then it would be like
Greater = If (Actual_Duration>Planned_Duration,"Yes","No")
and you would then use that column to feed your slicer.
For a measure version you would need to feed the slicer from a disconnected table.
Hi @Anonymous
To make it more clear, you need create a Calculated column and then use the new column to create Slicer. Calculated column used to compare ACTUAL_DURATION with PLANNED_DURATION:
GreaterOrNot = If ('DURATION'[ACTUAL_DURATION]>'DURATION'[PLANNED_DURATION],"Yes","No")
Test result:
Attached the pbix file as reference.
Best Regards,
Community Support Team _ Caiyun
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly. If you still have problems on it, please feel free to let us know. Thanks a lot!
The big question here is if you can do it as a column or if you need a measure.
If you can do it as a column then it would be like
Greater = If (Actual_Duration>Planned_Duration,"Yes","No")
and you would then use that column to feed your slicer.
For a measure version you would need to feed the slicer from a disconnected table.
Check out the July 2025 Power BI update to learn about new features.
User | Count |
---|---|
28 | |
12 | |
10 | |
10 | |
6 |