Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
amruta_j
Partner - Contributor III
Partner - Contributor III

Showing two years of data in chart without selection

Hi All,

Requirement is like I need to show latest two years of data in Combo chart(i.e. 2018 & 2019), but after selection of year, it should show only selected year's (2018 )data.

Currently I'm using below formula:

if(GetSelectedCount(Year)>0,
count(distinct{<Ppty_Txn_Type2-={'Refinancing'}>}Record_ID),
count(distinct{<Year={">=$(vPrevYear)"},Ppty_Txn_Type2-={'Refinancing'}>}Record_ID)
)

But with this formula, i'm getting all the years on X-Axis as attached.

Please help with this requirement.

2 Replies
martinpohl
Partner - Master
Partner - Master

change your expression:

count(distinct{<Year={$(=max(Year)),$(=max(Year)-1)},Ppty_Txn_Type2-={'Refinancing'}>}Record_ID)

Regards

sunny_talwar

Did you try to check 'Suppress Zero-Values' on the presentation tab of the chart properties?