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

Announcements
Discover how organizations are unlocking new revenue streams: Watch here
cancel
Showing results for 
Search instead for 
Did you mean: 
amien
Specialist
Specialist

how can i color a certain row in a pivot

i'm using not if ROWNO = 16,BLUE()

workd great, but it will kill my suppress zero values. And i need that too.

any other way to solve this?

1 Solution

Accepted Solutions
swuehl
MVP
MVP

Amien,

you could try something like

=if(aggr(rowno() =3,Year,Month),Yellow())

where Year and Month are the dimensions in my pivot table, and I use this expression as background color attribute expression.

But if you suppress zero values and you don't know which rows are suppressed, how do you know which row number to color? Is it just a fixed number?

Well, then above probably won't color the correct row number, since the aggr() won't suppress the rows, so the rowno() in the aggr() function is different from what you see in the pivot (and also, if your dimensions are not sorted by load order, you will also get a different row number).


View solution in original post

2 Replies
swuehl
MVP
MVP

Amien,

you could try something like

=if(aggr(rowno() =3,Year,Month),Yellow())

where Year and Month are the dimensions in my pivot table, and I use this expression as background color attribute expression.

But if you suppress zero values and you don't know which rows are suppressed, how do you know which row number to color? Is it just a fixed number?

Well, then above probably won't color the correct row number, since the aggr() won't suppress the rows, so the rowno() in the aggr() function is different from what you see in the pivot (and also, if your dimensions are not sorted by load order, you will also get a different row number).


amien
Specialist
Specialist
Author

Thanks for your help. Rowno would indeed not working. But i can do it on description

=if(aggr(AR_OMSCHRIJVINNG = '',AR_OMSCHRIJVINNG),Yellow())