About formatting background color

I try to compare the value between column A and B, and if the value of B is greater than A, the background of B will show as green, if less, show as red. I clicked optional formatting and chose greater than, it only has the option of value, I don’t know how to choose compare with another column.

1 Like

Hello @Sigrid, welcome to the QuickSight community!

You are going to want to build this functionality in a calculated field, and format the background color based on that output. I’ll provide an example:

Background Color = ifelse({column B} > {column A}, 1, 0)

Now, you can use this calculated field to determine the conditional formatting for column B. You would have a green background if the result is 1, or a red background if it is 0. I’ll mark this as the solution, but please let me know if you have any remaining questions!

1 Like

I made it! THX for your help ::

1 Like