Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Techies,
For this bar chart, I have some conditions, please help me to achieve that.
Conditions:
1. Colors are fixed (ash and blue)
2. The chart should not change on selection. For example, if I select kamal or any name the chart should remain same.
How do I nullify the selection !!!
Here I have attached a sample app to play around.
For the colours change the colour to expression and then use an expression like;
If (year = 'CY', RGB(165,165,165), if(year = 'PY', RGB(90,155,213)));
To stop the chart changing on selections you need to place a {1} in your expression, something like;
=sum({1}Value)
The {1} marker defines the record set to ALL.
Thanks
Hi Gareth wilson,
For colors I have already done what you said. But for selection {1} is not working. Because, even when I select Kamal
it should display like this
and not like this
Could you post the expression, I havent got sense on this laptop to open the app
Hi Gareth Wilson,
Here I have attached qlik view app.
Expression:
IF(type='CY' ,sum({1}CYSales),
if(type='PY',SUM({1}PYSales)))
NOTE: My requirement is for qlik sense.
The if statement is throwing off the set analysis marker.
try using
sum({1}if(type='CY',CYSales,PYSales))
!
And for your colours;
You create expressions for colors in the properties panel.
Do the following:
Hi Gareth Wilson,
Excellent!!!
But I have a catch here. In real scenario I will use something like this (should have mentioned earlier),
Expression:
IF(type='CY' ,sum({<$(vSetForCurrentYear)>}Sales),
if(type='PY',SUM({<$(vSetForPreviousYear)>}Sales)))
in this case I can not put the sum outside if.
How do I achieve this....
In this case try using
IF(type='CY' ,sum({1<$(vSetForCurrentYear)>}Sales),
if(type='PY',SUM({1<$(vSetForPreviousYear)>}Sales)))