Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Coming your way, the Qlik Data Revolution Virtual Summit. October 27-29. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Creator III
Creator III

stacked and combo chart

i want graph like this but the years in line chart is not changing dynamically so i have created manual but its not sufficient i want to change it as dynamically please suggest and i have category as dimension and in expressions are  shown in  below image i make selections on 2014 and 2015 compare the sales and show the difference in line chartUntitled.pngte

8 Replies
Highlighted

Can you change your Line expression like below

Sum(Sales) - Above(Sum(Sales))

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
Highlighted

Would you be able to share a sample app to see what you have?

Highlighted
Creator III
Creator III

load * inline [Sales, Category, Year

100,furniture,2014

220,furniture,2015

330,furniture,2016

33,furniture,2017

100,powder,2014

220,powder,2015

330,powder,2016

33,powder,2017];

this data is enough and dimension is category and expression is shown in above image

Highlighted

Is there a maximum number of years you will show? Like 4 years maximum at a time?

Highlighted
Creator III
Creator III

its example data

Highlighted

I know

Highlighted
Partner
Partner

Hello,

Maybe this will help you:

sum({<Year={"$(=max(Year))"}>}Sales) -sum({< Year-={"$(=max(Year))"}> * <Year=P(Year)>}Sales)

it takes the max year from your selection in the first expression and for the other makes the sum for all years in your selection excluding the max year (which is calculated in the first expression) and t's dynamical

Hope it helps,

Andrei

Highlighted

Hi,

maybe the answers in your other thread regarding this question are helpful?

stacked chart

Please also review your open threads and close those who received correct answers:

Qlik Community Tip: Marking Replies as Correct or Helpful

thanks

regards

Marco