Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Conditional background on dimension in Pivot

Hi,

I currently got a Pivot table with about 5 dimensions (some placed horizontally, some vertically). My third (horizontal) dimension is 'MONEY'. Now I want to set the background color of any cells in this dimension to green when a variable called COLOR_CODE is 0 for said 'MONEY' amount (specified in a table). However the expression for the background color isn't working at all (it's showing random fields in green). Should I specify 'Money' in the statement somewhere, despite it being the dimension?

I've set this as follows;

=If(COLOR_CODE = 0, rgb(108,179,63))

2 Replies
Oleg_Troyansky
Partner Ambassador/MVP
Partner Ambassador/MVP

it would be helpful to see a small example of your app.

swuehl
MVP
MVP

Could COLOR_CODE show more than one value per MONEY dimension value?

What do you see in the cells when adding another expression

=COLOR_CODE

If you see a lot of NULL ('-') when you are expecting a value, what do you get with

=CONCAT(DISTINCT  COLOR_CODE,', ')

Note that COLOR_CODE is in fact aggregated using Only() function, so this only works if there is a unique value to show.

Use Aggregation Functions!