Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello All,
Some one explain me below logic in simple terms?
sum({$<CancelDateNum_OO={">=$(vCurrentMonthStartDateNum) <=$(vMaxShipDateNum)"}=>} Quantity_OO *UNIT_SELLING_PRICE_OO)
Thanks,
Dinesh
You will get sum of (Quntity*unitsellingprice) cancel date those current month start date number is greater than is equal to and less than is equal to max ship date number
It will give sum of value for " Quantity_OO *UNIT_SELLING_PRICE_OO" with range between
vCurrentMonthStartDateNum and vMaxShipDateNum
This s giving you Sum of Sales for Date CancelDateNum_OO range between vCurrentMonthStartDateNum &vMaxShipDateNum
For eg.
Sum of Sales where CancelDateNum_OO between '01/08/2017' and '31/08/2017'
Here,vCurrentMonthStartDateNum='01/08/2017'
vMaxShipDateNum='31/08/2017'
The above expression gives Sum and product of ( Quantity * Unit ) Quantity_OO *UNIT_SELLING_PRICE_OO
and after that give SUM or SUM( Quantity_OO *UNIT_SELLING_PRICE_OO ) BUt in the particular date whether it is selected by calendar object or dynamically.
Ex:-
vCurrentMonthStartDateNum = 01/09/2017
vMaxShipDateNum = 02/09/2017 or (depend on selection ex:- 30/09/2017)
Which is done by this SET expression CancelDateNum_OO={">=$(vCurrentMonthStartDateNum) <=$(vMaxShipDateNum)"}=>}
It will give you the Sum of [Quantity_OO *UNIT_SELLING_PRICE_OO] on Current selection data set
only for the records having CancelDateNum_OO value in the range >=$(vCurrentMonthStartDateNum) and <=$(vMaxShipDateNum).
For Example.
vCurrentMonthStartDateNum='08/01/2017'
vMaxShipDateNum='08/15/2017'
It will give the sum of selling_price for records which are having CancelDateNum in between '08/01/2017' & '08/15/2017'.
Spliting the Set expression for easy understanding
Aggregation is sum(Quantity_OO *UNIT_SELLING_PRICE_OO)
Set identifier is $ (Current selection)
set Modifier Field is CancelDateNum_OO
Element list in Set Modifier Field is a Search String with a Range (It consider record having CancelDateNum_OO Value greater than eqaul to $(vCurrentMonthStartDateNum) but less than equal to $(vMaxShipDateNum))
Kushal,
Thanks for your reply
my issue hear is on starting of every month my numbers look bad, for example what if my
vCurrentMonthStartDateNum='01/09/2017'
vMaxShipDateNum='31/08/2017'
what result it give?
Thanks,
D
Thanks Karthik,
One question as I posted earlier
my issue hear is on starting of every month my numbers look bad, for example what if my
vCurrentMonthStartDateNum='01/09/2017'
vMaxShipDateNum='31/08/2017'
what result it give?
and how come I get around this issue ?
Thanks,
D
Can you explain your exact requirement?
Try the below set expression using variables and let me know whether it fits to your requirement
sum({$<CancelDateNum_OO={" >=$(vDate1) <=$(vDate2) "}=>} Quantity_OO *UNIT_SELLING_PRICE_OO)
Variable declarations:
vDate1
if(num($(vCurrentMonthStartDateNum))<num(vMaxShipDateNum),$(vCurrentMonthStartDateNum),$(vMaxShipDateNum))
vDate2
if(num($(vCurrentMonthStartDateNum))<num($(vMaxShipDateNum)),$(vMaxShipDateNum),$(vCurrentMonthStartDateNum))
what is expression in both variables?