Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
lukasrubner
Contributor
Contributor

Pivot Table with conditional formatting for different KPIs that is unaffected by selections

Hell Everyone,

I am trying to create a table containing different formats (Whole numbers and percentages). This table also should not be affected by selections in a specific dimension (Sampletable attached).

I currently have a solution where my expression consists of an If statement like this:

IF(KPI = KPI1 OR KPI = KPI3 OR KPI = KPI4, num(expression,'#.'), num(expression, '#.##%'))

 

This does work as long as I do not select a KPI (needed in another part of the App). However, once I do select a KPI the formatting condition is ignored and all KPIs formatted according to the selection.

 

Is there a way to prevent that from happening?

1 Solution

Accepted Solutions
rubenmarin

Hi, try adding {1} to ignore selctions, also macth can be easier to manage than adding 'ors':
If(Match(Only({1} KPI), 'KPI1','KPI3','KPI4'), num(expression,'#.'), num(expression, '#.##%'))

Only() returns the same value, is only used to apply set analysis ({1}).

View solution in original post

1 Reply
rubenmarin

Hi, try adding {1} to ignore selctions, also macth can be easier to manage than adding 'ors':
If(Match(Only({1} KPI), 'KPI1','KPI3','KPI4'), num(expression,'#.'), num(expression, '#.##%'))

Only() returns the same value, is only used to apply set analysis ({1}).