Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
i want to display last two months data in pivot table
I am doing this using the following expression in qlikview but that doesn't work for me. Please help.
Count({<Month={">=$(=Month,-3)) <=$(=Month)"}>}Item)
OR
Count({<Month={">=$('01-05-2020')<=$('30-06-2020')"}>}Item)
Hi, what is the format of your month field?
I think you should create in your preceding load statement a YearMonth field with
load Date#(YearField&MonthField, 'YYYYMM') as YearMonth
And use in your SA something like
Count({<YearMonth={">=$(=AddMonths(Max(YearMonth), -3))"}>} Item)
Hi, what is the format of your month field?
I think you should create in your preceding load statement a YearMonth field with
load Date#(YearField&MonthField, 'YYYYMM') as YearMonth
And use in your SA something like
Count({<YearMonth={">=$(=AddMonths(Max(YearMonth), -3))"}>} Item)
I have already stored Month and Year into Month Field and change into Date format 'MM-YYYY' i.e. 07-2020. But the count expression is not working. It is not displaying any data.
Load
Date(MonthStart(OrderDate),'MM-YYYY') as Month
And if you try with
load
Date#(Year(OrderDate) & Month(OrderDate), 'YYYYMM') as Month
Still not working. Please help me.
Please check what's wrong.
With Month as dimension you an use below expression
=sum({<Month>}aggr(rangesum(above(total count({<Month>}Item),0,3)), (Month,(NUMERIC, ASCENDING))))*avg(1)
Kush your expression has error. Kindly give me correct one
Expression seems fine. Just change the field name highlighted with your actual field names.
=sum({<Month>}aggr(rangesum(above(total count({<Month>}Item),0,3)), (Month,(NUMERIC, ASCENDING))))*avg(1)