Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Comparing two Columns in a the same Chart

I have a chart with two columns of data both using the same Fieldname but existing in different states.

The expressions are:

 

=Sum({[Chart 1]} Fieldname)

 

 

=Sum({[Chart 2]} Fieldname)

 

I am trying to write a expression under the background color box that would compare the number in both columns and highlight them in yellow if the are different.  What I have written is below.  The expression is OK but it is not showing up as yellow where it is different.  Any idea on what is wrong in the expression?

=If(Aggr((Sum({[Chart 1]} [Addressable Spend])) <> (Sum({[Chart 2]} [Addressable Spend])), yellow())

1 Solution

Accepted Solutions
sunny_talwar

Why not just this:

If(Sum({[Chart 1]} Fieldname) <> Sum({[Chart 2]} Fieldname), Yellow())

View solution in original post

4 Replies
sunny_talwar

Why not just this:

If(Sum({[Chart 1]} Fieldname) <> Sum({[Chart 2]} Fieldname), Yellow())

rupamjyotidas
Specialist
Specialist

Probably

if(Coumn(1)<>Column(2),Yellow())

Anonymous
Not applicable
Author

That worked perfectly.  Thanks for your help!

sunny_talwar

No problem at all... Happy to help