Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Need help with two measures I'm trying to create to be inserted as column's in my app.
The Prev Month is set to this:
Sum({<[Common Date.autoCalendar.Date]={">=$(=(MonthStart(AddMonths(Today([Common Date]),-1)))))<=$(=(MonthEnd(AddMonths(Today([Common Date]),-1)))))"},Year=,Month=>} [Total Cost])
It returns this below:
The data in the table is only showing $0
Any Ideas on what I have wrong and how to set a measure to the Previous 12 Months as well?
In your expression, try to adjust the syntax, there are parentheses left) in the analysis of the set.
Example previous month
Sum({<[Common Date.autoCalendar.Date]={">=$(=(MonthStart(Today(),-1)))<=$(=(MonthEnd(Today(),-1)))"},Year=,[ Month ]=>} [Total Cost])
Example -12
sum({1<[Common Date.autoCalendar.Date]={">=$(=AddMonths(Monthstart(today()),-12))<=$(=MonthEnd(today(),-1))"}>} [Total Cost])
In this example, without considering the current month
Att,
Matheus
In your expression, try to adjust the syntax, there are parentheses left) in the analysis of the set.
Example previous month
Sum({<[Common Date.autoCalendar.Date]={">=$(=(MonthStart(Today(),-1)))<=$(=(MonthEnd(Today(),-1)))"},Year=,[ Month ]=>} [Total Cost])
Example -12
sum({1<[Common Date.autoCalendar.Date]={">=$(=AddMonths(Monthstart(today()),-12))<=$(=MonthEnd(today(),-1))"}>} [Total Cost])
In this example, without considering the current month
Att,
Matheus
Thank you so much!!! I'm new to Qlik so the editor is a learning challenge for me.