Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
Our next Qlik Insider session will cover new key capabilities. Join us August 11th REGISTER TODAY
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

count

Hi All,

Can any one help on the below scenario. I have Manager, Branch, Sales fields, now I would like to show a stacked bar chart with

Manager as dimension and  count(branch) as expression as stacked bar chart. for that I have 3 colors when for each bar segment,

if sum(sales)<450,RGB(0,68,0)), if(sum(sales)>450,RGB(0,168,0)),if(sum(sales) >600,RGB(10,168,30)), and in these segments I would like to show the count of braces. which are meeting the above conditions.

Regards

John

1 Solution

Accepted Solutions
jagan
Luminary Alumni
Luminary Alumni

Hi,

Please find attached file for solution.

Regards,

Jagan.

View solution in original post

8 Replies
jsingh71
Partner
Partner

Something like this, see attachment

I am using personal edition..if you need any changes then plz attach screenshot.


jagan
Luminary Alumni
Luminary Alumni

Hi,

Please find attached file for solution.

Used below expressions

=Sum(aggr(if(sum(sales)<=450, 1), Manager, Branch))

=Sum(Aggr(if(sum(sales)>600, 1),Manager, Branch))

=Sum(Aggr(if(sum(sales)>400 and sum(sales)<=650, 1),Manager, Branch))

Regards,

Jagan.

Not applicable
Author

PFA

Not applicable
Author

Hi Jagan  Thanks,

I didn't find the attachment. and I have used the expressions but it is displaying like group but I want it in stacked bar, how can I achieve it.

Regards

John

jagan
Luminary Alumni
Luminary Alumni

Hi,

Please find attached file for solution.

Regards,

Jagan.

View solution in original post

Not applicable
Author

Hi Jagan, thanks it works. I have one doubt here if my branch is duplicated several time at that time also I want only distinct records how can I get it.

Regards

John

jagan
Luminary Alumni
Luminary Alumni

Hi,

Your number range is

<=450

>600

>400 <=650


So, the second range and third range you will get duplicate count, so fix the ranges so that it won't satisfy for two conditions.


Example:

<=400

>400 <=650

>650


Now you won't get duplicates.


Regards,

Jagan.

Not applicable
Author

Hi Jagan,

Now I want show those branch numbers whenever a click has happened on any segment of the bar , how can I show those branches, could you please help me on that.

Regards

John