Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All ,
I have a query based on period selection in my period.
Lets consider my requirement here like below.
If my selection is Year=2016 and Month = 06.and I have a Filters (YTD,MTD,PY Year)
If i slect YTD Should show 2016.06 date only.
If i slect MTD Should show current - previous month data.
If i slect PY Year Last Year Current month - previous month data only.
Can any one tell me how to achieve this.
Create ISLAND Table?
Load * Inline [
Selections
YTD
MTD
PY Year
];
ID is dimension
And use formula like below
Pick(Match(Selections, 'YTD','MTD','PY Year'),
Sum(Sales),
(Sum({<Month = {'$(=Max(Month))'}>}Sales)-Sum({<Month = {'$(=AddYears(Max(Month), -1))'}>}Sales)),
(Sum({<Year = {'$(=AddYears(Max(Year), -1))'}, Month = {'$(=Max(Month))'}>}Sales)-Sum({<Year = {'$(=AddYears(Max(Year), -1))'}, Month = {'$(=Max(Month)-1)'}>}Sales))