Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
how two covert this expresion to set analysis expression
sum(if( mid($(DATE),3,2) = right(DATE_PRODUCTION,2) ,amout))
Hi Souad,
Create a Column in your script for Right(DATE_PRODUCTION,2) AS DATE_PRODUCTION_NEW.
And use below Expression.
Sum({<DATE_PRODUCTION_NEW = {"$(=Mid(DATE),3,2)"} >} Amount)
Regards
Sumeet
i am not allow to modify the script
Is DATE in sum(if( mid($(DATE),3,2).... a variable?
if the IF statement is working, not necessarily a better idea to use SET Expression.
Because the fields do not contain the exact matching you are after, it gets a bit more complex to do a Set Expression since left side must be a field only.
In order to do this, there must be a primary key,e.g. ID_FIELD, in your data set
Sum({<ID_FIELD= {"=$(=Mid(DATE),3,2) )= $(=right(DATE_PRODUCTION,2))"} >} Amount)
May be try this?
= sum({< Amount = {"=if( mid($(DATE),3,2) = right(DATE_PRODUCTION,2) ,amount)"} >} Amount)