Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
bell_byloli
Contributor III
Contributor III

Trendline dissapears while making a selection

hello all,

i have a combo chart which shows the last 6 months revenue based on the latest month . Dimensions are Month and region(Asia, europe and america), the chart is plotted expressions of revenue for bar chart and a line . however in default view, based on expression

sum ({<Year=,Quarter=,Month=,MonthYearNew={">=$(=addmonths(max(MonthYearNew),-5)) <=$(=Max(MonthYearNew))"}>} (revenue))

i am able to view the trendline. However when i make a selection of the month , the chart shows the 6 months data from the month selected, however it does not show the trendline, it just shows a symbol over the selected month(diamond).

Please Can any one suggest how we can view the trendline for any selection.

1 Solution

Accepted Solutions
sundarakumar
Specialist II
Specialist II


Hi Belliappa,

PFA.

It is working now.

-Sundar

View solution in original post

12 Replies
Nicole-Smith

Try adding a 1 into the set analysis in order to ignore the selection:

sum ({1<Year=,Quarter=,Month=,MonthYearNew={">=$(=addmonths(max(MonthYearNew),-5)) <=$(=Max(MonthYearNew))"}>} (revenue))

bell_byloli
Contributor III
Contributor III
Author

thanks Nicole , i tried this option but i am still unable to the get the trendline when selecting a month

sujeetsingh
Master III
Master III

Try using if statement

bell_byloli
Contributor III
Contributor III
Author

hey Sujeet thanks , i am not sure if i follow your method.Could please provide an example.

sundarakumar
Specialist II
Specialist II

Hi Belliappa,

R u using single expression to show both line and chart or two different expressions?

and Plese check in which field( "Month" or "Month new year") u r making the month selection?
Please try to post a sample or screen shot of ur chart and expression tab...

-Sundar

bell_byloli
Contributor III
Contributor III
Author

hello Sundarkumar, i have uploaded a sample file.

sundarakumar
Specialist II
Specialist II


Hi Belliappa,

PFA.

It is working now.

-Sundar

bell_byloli
Contributor III
Contributor III
Author

Thanks so much Sundarakumar..!

sundarakumar
Specialist II
Specialist II

Hi Belliappa,

While working on your app, i did some changes for calculating the dimension, hope it will help your development.

PFA.

Hope this helps.

-Sundar