Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dear Experts,
I am trying to get last 3 months sale but getting only the date selected one day sale. i am using below expression:
SUM({<TRX_DATE = {"$(='>=' & v3MonthsBackDate)"}>}
(IF (TYPE = 'CM', QUANTITY_CREDITED , QUANTITY_INVOICED)/ IF(isnull(LTR_CV_RATE),1,LTR_CV_RATE))
)
where v3MonthsBackDate is a variable with below syntax:
=(ADDMONTHS(Max(TRX_DATE),-3))
Regards,
Zahid Rahim
Hi Rahim,
Could you please send some sample data.
What I understand is on every date you need sum of last 3 months sales
Sum({<TRX_DATE={">=$(=TRX_DATE(Addmonths(max(TRX_DATE),-3)))"}>}
(IF (TYPE = 'CM', QUANTITY_CREDITED , QUANTITY_INVOICED)/ IF(isnull(LTR_CV_RATE),1,LTR_CV_RATE))
)
Regards,
Neha
Two questions
1) Are you selecting in TRX_DATE field or another field?
2) What is the format for TRX_DATE? Do you see the same format when you put this ='>=' & v3MonthsBackDate a text box object?
1. Same Field i-e TRX_DATE
2. Format is same i have checked in a textbox MM/DD/YYYY the default.
Don't see anything wrong with your expression.... But tried to simplify the denominator using Alt function... see if that changes anything?
Sum({<TRX_DATE = {"$(='>=' & v3MonthsBackDate)"}>} If(TYPE = 'CM', QUANTITY_CREDITED, QUANTITY_INVOICED)/Alt(LTR_CV_RATE,1))
try removing the dollar before the variablein the set expression
=ADDMONTHS(Max(TRX_DATE),-3) as variable description
Dear Sunny,
When i remove the filter then i can see last 3 months sale perfectly. But when i apply the filter and select any date then i can see only that date sale.
Regards,
Zahid Rahim
Hahahahaha I have read this above... I understand your issue... but just from your expression I don't see why this would happen... your expression looks absolutely correct to me. do you have a calculated dimension?
No there is no calculated dimension.
no idea zahidrahim.ocp because like I mentioned your expression looks good to me.... but I might be missing something... may be someone else might be able to find the mistake
dis you try my suggestion ? This didn't work?