Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
HI Experts,
I have one year list box in that i am having data like 2010 to 2016 and respected sales
If click on 2013year then i want see the total sales for 2013 ,2012,2011 and 2010.
How to calculate the total based on the selection?
So, sales for all years on and before the selected year? May be this...
Sum({<Year = {"$(='<=' & Max(Year))"}>}Sales)
HI Thanks for the reply,
The above expression is correct but at the same time it is calculating the all months from all years right?
But if i click on 2013 year and 4 th month then how to calculate ?
What should happen when you select the 4th month? You want to see the sum of sales of 4th month for 2013, 2012, 2011... etc?
When we select "2013" and month "04" we would see 2010 - 2013 (correct!) but only for month 04
i want to see 2010 - 2012 month 1-12 and 2013 month 1 - 4.
May be create a monthcounter in the script for Master Calendar like this
AutoNumber(MonthName(Date)) as MonthCounter
and then use this
Sum({<Year, MonthCounter = {"$(='<=' & Max(MonthCounter))"}>}Sales)
hi,
The month field is available in my data model and if i use the below expression then i am getting correct data for years
Sum({<Year = {"$(='<=' & Max(Year))"}>}Sales) but i want months also
Hi,
if you have date field,you can use max of date in set analysis,
I have done a simple scenario in attached file,I hope it can help.
You want months also? I am not sure I follow?