Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
yonutssy
Contributor
Contributor

Filter excludes values

Hello Qlik Sense Community,

I have a filter that is acting very strange.

Anytime I select 'Last 12 months through last month' I get some values, but without values from 'Last 6 months' or 'Last 3 months'. Is there a way to make it work correctly and to get the values from those 2 options too? 

The filter looks like this:

= if(Lead_Date>= TP_Last_3_Thru_LM_ST_Min and Lead_Date <= TP_Last_3_Thru_LM_ST_Max, 'Last 3 months through last month',
if(Lead_Date>= TP_Last_3_Thru_LM_CT_Min and Lead_Date <= TP_Last_3_Thru_LM_CT_Max, 'Last 3 months through last month',
if(Lead_Date>= TP_Last_6_Thru_LM_ST_Min and Lead_Date <= TP_Last_6_Thru_LM_ST_Max, 'Last 6 months through last month',
if(Lead_Date>= TP_Last_6_Thru_LM_CT_Min and Lead_Date <= TP_Last_6_Thru_LM_CT_Max, 'Last 6 months through last month',
if(Lead_Date >= TP_Last_12_Thru_LM_ST_Min and Lead_Date <= TP_Last_12_Thru_LM_ST_Max, 'Last 12 months through last month',
if(Lead_Date >= TP_Last_12_Thru_LM_CT_Min and Lead_Date <= TP_Last_12_Thru_LM_CT_Max,'Last 12 months through last month'
))))))

 

 

Labels (3)
1 Reply
yonutssy
Contributor
Contributor
Author

What I am trying to achieve is that I want to see a comparison between Selected Timeframe and Comparison Timeframe, but dynamically using the filter. Just like this: 

yonutssy_0-1642515813881.png

 

Also, the formula for above image is this:

if((Lead_Date>= TP_Last_3_Thru_LM_ST_Min and Lead_Date <= TP_Last_3_Thru_LM_ST_Max)
OR (Lead_Date>= TP_Last_6_Thru_LM_ST_Min and Lead_Date <= TP_Last_6_Thru_LM_ST_Max)
OR (Lead_Date >= TP_Last_12_Thru_LM_ST_Min and Lead_Date <= TP_Last_12_Thru_LM_ST_Max) , 'Selected Timeframe',
if((Lead_Date>= TP_Last_3_Thru_LM_CT_Min and Lead_Date <= TP_Last_3_Thru_LM_CT_Max)
OR (Lead_Date>= TP_Last_6_Thru_LM_CT_Min and Lead_Date <= TP_Last_6_Thru_LM_CT_Max)
OR (Lead_Date >= TP_Last_12_Thru_LM_CT_Min and Lead_Date <= TP_Last_12_Thru_LM_CT_Max), 'Comparison Timeframe'
))