Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All
My Table have below expression display YTD sales work fine :-
Sum({$<year = {$(=Max(year)-1)}, month = {"<=$(=Max({<year={$(=Max(year))}, sales = {'*'}>} month))"}>}sales/Rate)
And below display YTD LY sales :-
Sum({$<year = {$(=Max(year)-1)}, month = {"<=$(=Max({<year={$(=Max(year))}, sales = {'*'}>} month))"}>}sales/Rate)
My question is when user need to compare whole year 2015 vs 2016 from Jan till june sales , user click on year=2016 and month = 12
the table display null value.
May i know how to make it display YTD sales amount for both column ?
Paul
my qvw
Hi,
In PY YTD dont set month field.Nullify it.
Try like,
Sum({$<year = {$(=Max(year)-1)}, month = , sales = {'*'}>} month))"}>}sales/Rate)
Regards
Not clear from your explanation. Can you provide output which you are looking for?
You try to use ADDMONTHS() & ADDYEARS() to your previous year & Month .
Try to remove
,sales={'*'}
or replace with
,sales=
Hi,
or you can simply set Month value in set analysis for PY YTD.
try like,
Sum({$<year = {$(=Max(year)-1)}, month = {"<=12"}, sales = {'*'}>} month))"}>}sales/Rate)
Regards
Hi Antonio
Thank you very much , this is what i am looking for.
Paul
Hi Max
i try it return null value.
Paul
Hi Manish
I have already got the solution on this post , and i have mark correct answer. , that is :-
Try to remove
,sales={'*'}
or replace with
,sales=
Today i learn 2 thing about
,sales={'*'}
1) This allow user not select any value and it will select june.
2) if {'*'} are remove user can select mth =12 and yr=2016 and it can display value.
Paul