Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Sam_Thomas
Creator
Creator

How can I create a bar chart based on the sum of values across multiple fields?

Hi, new to Qliksense, so hoping I can explain my situation well enough. 

I am trying to create a reporting dashboard to give some key figures and KPI's. First of which would be a bar chart that displays the total number of times 'R', 'A' and 'G' appear. However, these values can appear in 7 different fields. 

The data is a survey that is being completed by engineers. They can input R, A or G for several questions. How can I count the total amount of values for these 3 choices and display in a chart (or a better way you might suggest). 

Thanks in advance. 

1 Solution

Accepted Solutions
Or
MVP
MVP

Count({<Field1={'R'}  >} Field1) + Count({<Field2={'R'}  >} Field2) + ... + Count({<Field7={'R'}  >} Field7)

Same for the other two options, replacing R with A and G.

 

View solution in original post

4 Replies
Sam_Thomas
Creator
Creator
Author

I imagine 'count' rather than 'sum' would have been a better word to use for the title. 

Or
MVP
MVP

Count({<Field1={'R'}  >} Field1) + Count({<Field2={'R'}  >} Field2) + ... + Count({<Field7={'R'}  >} Field7)

Same for the other two options, replacing R with A and G.

 

Sam_Thomas
Creator
Creator
Author

Thanks. Count didn't actually seem to work for me, but when I changed to SUM it did - probably me not explaining it properly but either way, your solution eventually got me to the right answer! Thanks. 

Or
MVP
MVP

Not sure how you can sum text values - what's the sum of R and G? But I'm glad you got it working!