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

Pivot table - show different format in total column

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!)

ApplesPearsTotal
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)

ApplesPearsTotal
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

1 Solution

Accepted Solutions
jonathandienst
Partner - Champion III
Partner - Champion III

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

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein

View solution in original post

3 Replies
anbu1984
Master III
Master III

If(Dimensionality()=0, round(sum(CompCount)/sum([Person HeadCount]),0.01),

round(sum(CompCount)/sum([Person HeadCount]),0.01)&' ('&sum(NonCount)&')'

)

jonathandienst
Partner - Champion III
Partner - Champion III

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

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Not applicable
Author

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