Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all
I recently got some help from you on concatenating 2 expressions in a pivot table chart, and this worked great, thank you....
http://community.qlik.com/thread/144456
....however, I now need to do the following:
- only show the concatenation in the main part of the table, but not for the total column
- apply different conditional formatting to the total column
e.g. This is how it currently looks(ignore numbers!)
Apples | Pears | Total | |
America | (3) 5% | (2) 10% | (5) 7% |
New Zealand | (10) 50% | (10) 50% | (20) 50% |
India | (3) 5% | (2) 10% | (5) 7% |
This is how it needs to look - no number in brackets in the total and different conditional formatting settings on the total figure as the total does not have the same targets as the individual items (apples, pears)
Apples | Pears | Total | |
America | (3) 5% | (2) 10% | 7% |
New Zealand | (10) 50% | (10) 50% | 50% |
India | (3) 5% | (2) 10% | 7% |
Please can you help?
Thank you
Hi
In a straight table or columns in a pivot table, use Dimensionality()
For row totals in pivot table, use SecondaryDimensionality(), like this:
=If(SecondaryDimensionality() = 0, <simple expression for total>, <concatenated expression for detail>)
HTH
Jonathan
If(Dimensionality()=0, round(sum(CompCount)/sum([Person HeadCount]),0.01),
round(sum(CompCount)/sum([Person HeadCount]),0.01)&' ('&sum(NonCount)&')'
)
Hi
In a straight table or columns in a pivot table, use Dimensionality()
For row totals in pivot table, use SecondaryDimensionality(), like this:
=If(SecondaryDimensionality() = 0, <simple expression for total>, <concatenated expression for detail>)
HTH
Jonathan
Thank you - that worked perfectly!
Now for the conditional formatting formatting aspect - is it the same expression?
=If(SecondaryDimensionality() = 0, <conditional formatting for total>, <conditional formatting for detail>)
Chloe