Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Sum of the same companies in different years

Hello,

I have different companies in different years. I want to calculate the sum of the same companies in the  bar chart. The sum also should be for the max date.Bar should look like this

Capture.PNG

19 Replies
Anonymous
Not applicable
Author

Company 43 is added in 2017

So, here are the screenshots . Sum Should be 28.78 Untitled.png

Capture.PNG

Untitled2.png

sunny_talwar

Isn't your year field called n.year? I am not sure if you need to change your set analysis to make sure it is n.year

Anonymous
Not applicable
Author

It works correctly, also when I click 2017 , everything is shown.

But when I click 2016  it doesn't work

Capture.PNG

sunny_talwar

What doesn't work? Can you share a sample and explain what you need?

consultant_bi
Creator
Creator

i think you want the sum for each companie displayed for each year , for example :

2016   A  50000

           B  60000

           C  59000

2017  A   100000

          B   80000

          C   55000

          X   70000

if you want like that you have to add two dimensions one for year and second for Companies and in the measure add sum(field)

rakeshkumar1890
Creator
Creator

Hope it may help you,

Digvijay_Singh

May be, you don't have 2015 data, so it shows nothing when you click 2016, what if you change it to Min(Year)? -

Sum({<Company = p({<Year = {"$(=Min(Year)"}>})>}Measure)

Anonymous
Not applicable
Author

Capture.PNG

Can I make the bar chart and and show new the new company as it is in this picture?

Anonymous
Not applicable
Author

Can I make the bar chart and and show the new company as it is in this picture?

Capture.PNG

sunny_talwar

I think you can... would you be able to share a sample app?