Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Announcements
Qlik Analytics Tour 2020 Online. Begins August 10th. Register Today
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted

Re: Use only Overlapping Months

Here you go

Highlighted
Creator II
Creator II

Re: Use only Overlapping Months

GR8 Thnx I guess the first step is successful, now the next step is  If I don't have any selections for the ETL Date, I would like to see the common months data for the most recent ETL Date and one Prior Date. So in this case By default I want to see May and Jan 2019 data for the common months between them?

Highlighted

Re: Use only Overlapping Months

Try this

Sum({<[Forecast Date] = {"=Count(DISTINCT {<[ETL Date] = {[$(=Date(Max([ETL Date])))], [$(=Date(Max([ETL Date], 2)))]}>} [ETL Date]) = 2"}, [ETL Date] = {"$(=Date(Max([ETL Date])))", "$(=Date(Max([ETL Date], 2)))"}>} Amount)
Highlighted
Creator II
Creator II

Re: Use only Overlapping Months

This Expression Rocks, giving me exactly what I want for one of the requirements. One last requirement is  that  by default I also want to show  the Amount for only the Current ETL Date with Matching months from the Previous ETL Date  and also show the Previous ETL Date amount only with Matching months from the current ETL Date. 

 

Highlighted

Re: Use only Overlapping Months

Isn't that what it is doing?

image.png

Here I am guessing that your default is no selection in ETL Date. If that is not what your default is, then what is your default?

Highlighted
Creator II
Creator II

Re: Use only Overlapping Months

Yes this is one of the requirements but this result set is giving me the sum of ETL Date 1, and ETL Date 2 for the common  months. My another requirement is that I want the sum of ETL Date 1 only for  the common Months between ETL Date 1 and ETL Date 2 and 

the sum of ETL Date 2 only for  the common Months between ETL Date 1 and ETL Date 2.

Both these are seperate KPI's. I think you are very close this solution also

 

 

Highlighted
Creator II
Creator II

Re: Use only Overlapping Months

Also when I make a selection in the ETL DAte the expression NUlls out

Highlighted
Creator II
Creator II

Re: Use only Overlapping Months

The qvw you sent was perfect but one last  requirement is  I would like to calculate the difference between the 2 Selected ETL dates. How can I do that with this expression? I mean 

Sum(Max ETL Date) - Sum(Previous ETL Date)