Skip to main content

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
CUSTOMERS ONLY: Now accepting customer applications for the 2023 Luminary Program: SUBMIT NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Stacked bar chart

Hi,

I have the tables attached ( where for clarity I have deleted the dimension rows as they are not useful for the chart I want to create).

The first table has the total, while the second is filtered by the value Sex='F' and the third one by the value Sex='M'

From that table/data I want to create a chart with stacked bars as the one I have attached.

However I cannot create that, as the dimensions I want to put on x axis are, in reality, expressions:

Exp1 =Sum ({<[Soc]={'001'}>}[cost 1])

Exp2 =sum({<[Class]={'C'}>} [sales 1])

Is there a way to achive that?

many thanks in advance,

5 Replies
Not applicable
Author

Hi,

Maybe this can help because I'm not sure if you can see what you want.

Not applicable
Author

Hi Rebeca,

unfortunatelly, the graph you posted is not what I want. Each bar should show the percentage of male and female, so for Exp1 it's the first bar and then for Exp2 the second bar in the chart I attached.

Hope now it's more clear, otherwise I have no problems to provide more examples if needed.

thanks,

Not applicable
Author

Hagakure, did you ever figure this out? I'm trying to do the exact same thing.  Thanks!

mbm
Employee
Employee

Here is an example of a stacked bar chart using multiple expression.

To create this I've added an inline table with the values I wish to display as my X axis labels and used that field as my primary dimension. Secondary dimension is Sex to create the stacked bars.

The expression uses conditional logic to match the dimension with the expression I want to calculate.

Not applicable
Author

Thanks!