Qlik Community

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

cancel
Showing results for 
Search instead for 
Did you mean: 
saradhi_it
Creator II
Creator II

Previous month selection issue

HI team 

I Have two years of data  From Jan 2018 to Dec 2019,   i got a requirement from the user when the user selects any month filter (list box or filter pane)  data should be calculated from  Mindate to the previous month based on the current selection 

Eg: if user selects  Dec 2019  data should be calculated from Jan 2018(Min date) to Nov 2019 

i tried so many expressions  

COUNT(distinct {<current_Month={"${=Date(MonthStart(max(current_Month), -1),'MMM-YY'))"},Status={'Confirmed '}>} Sales)

I had tried my expressions didn't work 

Labels (1)
1 Reply
PriyankaShivhare
Creator II
Creator II

May be like this:

sum({<Date={">$(=min({1}Date))<$(=addmonths(max(Date),-1))"},Status={'Confirmed'}>}Sales)

or

sum({<Date={"<=$(=addmonths(max(Date),-1))"},Status={'Confirmed'}>}Sales)

or

count({<Date={">$(=min({1}Date))<$(=addmonths(max(Date),-1))"},Status={'Confirmed'}>}Distinct [DimensionField])

 

Check for the Date format:

Thanks,

Priyanka