Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
in Qliksense
Current Month October
TTM ( trailing twelve months)—Since we are in Oct 2017 then it will start from Oct 2017 back to Nov 2016
PTTM (Previous trailing twelve months)--- Since we are in Oct 2017 then it will start from Oct 2016 back to Nov 2015
Set Analysis ( TTM) , there is a field called MonthIndex ( Year*12 +Month) using this field I have subtracted 12 to give me the bucket values of TTM & PTTM
Sum( {<MonthIndex = {"$(='>' & $(vFixedTTM) & '<=' & $(vFixedMonthIndex))"} >} SalesAmount)
Issue or What customer is expecting :
If you see above screen shot the line is the issue, in the sorting we can do either January to December or December to January. But customer wants the sorting to be as shown in the table on the left Start from the current month to end of TTM. If Customer picks June then it should start from June to July
Please let me know if you need any additional info
Vinay - Would you be able to share a qvf to test it out
sort the dimension by Monthindex . use sort by expression?
regards
Pradosh
tried but not working
will try rey Sunny and update you
Attached is the sample data
What is SalesAmount in the Excel? Full Revenue?>
It just t give you full data for all the months. basically i want to put this data in line chart and if i pick any month sorting should be from that month to back to 12 months . and dimension should be month only not year
Try this as your sorting expression
=Max({<MonthIndex = {"$(='>' & $(vFixedTTM) & '<=' & $(vFixedMonthIndex))"}>} MonthYear)
Where I created MonthYear like this
MonthName(Date) as MonthYear
But you might be able to use MonthIndex
let me try that and i will update you rey