Qlik Community

QlikView Creating Analytics

Discussion Board for collaboration related to Creating Analytics for QlikView.

Announcements
QlikWorld, June 24-25, 2020. Free virtual event for DI and DA gurus. Register Today
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Not applicable

background colour on condition

Hi,

may someone of you can help me.

I used a condition for the Background colour.

=if(doclinenum = assetline_doclinenum, RGB(98,172,30))

It is working fine when I have only one line in the first table. But it is not working if I have more than one line.

What should be adapted in the condition ?

Thanks for your help in advance.

Chris

1 Solution

Accepted Solutions
Highlighted

Re: background colour on condition

I don't have the data to test, but can you try this:

Aggr(If(doclinenum = assetline_doclinenum, RGB(98,172,30)), doclinenum, assetline_doclinenum)

View solution in original post

6 Replies
Highlighted

Re: background colour on condition

I don't see assetline_doclinenum in any of the snapshots. Can you clarify where is that information coming from?

Highlighted
Contributor III
Contributor III

Re: background colour on condition

can u prepeare qvw file with reduced data?

Highlighted
Not applicable

Re: background colour on condition

yes of course. sorry.

assetline_doclinenum is in the first table column doclinenum.

and doclinenum is the column doclinenum from the second table.

Highlighted
MVP & Luminary
MVP & Luminary

Re: background colour on condition

The reason will probably be that there not unique field-values and no aggregations are used so that a query on field returned NULL. A very good explanation and alternative could you find here: Colors in charts.

- Marcus

Highlighted

Re: background colour on condition

I don't have the data to test, but can you try this:

Aggr(If(doclinenum = assetline_doclinenum, RGB(98,172,30)), doclinenum, assetline_doclinenum)

View solution in original post

Highlighted
Not applicable

Re: background colour on condition

Sunny, you are my hero. It works now.