Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All
I have a Table , i am using below expression, is working fine :-
sum({$<year = {$(=max(year) - $(=if(max(month) = 1, 1, 0)))}, month = {$(=num(month(addmonths(max(YearMonth), -1))))}>} Invoice_Amt_SGD/1000)
My issue is when the number increase to 7 , it display null :-
sum({$<year = {$(=max(year) - $(=if(max(month) = 1, 1, 0)))}, month = {$(=num(month(addmonths(max(YearMonth), -7))))}>} Invoice_Amt_SGD/1000)
Can some one advise me how to check where it the error ?
Paul
Dear Paul,
Your expression is returning Dec 2014 as year condition your extracting is returning 2014.
Please use the following expression:
sum({$<year = {$(=num(year(addmonths(max(YearMonth), -7))))}, month = {$(=num(month(addmonths(max(YearMonth), -7))))}>} Invoice_Amt_SGD/1000)
Change your other caluclations also according to the above expression. Hope this helps..
Please mark this as correct, if your result is as expected.
Regards,
Venkat
My QV doc
Dear Paul,
Your expression is returning Dec 2014 as year condition your extracting is returning 2014.
Please use the following expression:
sum({$<year = {$(=num(year(addmonths(max(YearMonth), -7))))}, month = {$(=num(month(addmonths(max(YearMonth), -7))))}>} Invoice_Amt_SGD/1000)
Change your other caluclations also according to the above expression. Hope this helps..
Please mark this as correct, if your result is as expected.
Regards,
Venkat
Hi Ven
Thank you very much for your help , with out it i will not be able to figure out.
Paul