on 2023 Oct 31 5:13 PM
Hello Team,
Can you please help in rounding the value to nearest 10 places. I have already tied implementing below blog given by Xavier. I would like to convert value from 4020 to 4000 .
Tried with formula as:- round(‘halfUp’,round(‘halfUp’,lumpSum)/10)*10. It throws the same value as 4020.
https://blogs.sap.com/2020/09/29/how-to-use-dates-in-formulas-in-compensation-worksheets/
Can you pl help me in validating the formula to convert the value to 4000.
Thanks
Ritanshi
Request clarification before answering.
Hi Ritanshi,
If you need to convert 4020 to nearest 10, then I guess it would be exactly 4020.
But if you need to convert 4020 to 4000, which is to the nearest thousand, I would write it like that :
round(‘halfUp’, (lumpSum/1000) )*1000
Let me know if it works for you.
Best,
Alexandra
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
4020 to 4000 could also be nearest hundred with round(‘halfUp’, (lumpSum/100) )*100
Hello Ritanshi,
If you want to round to the nearest hundred, try following:
round(‘halfUp’, lumpSum/100)*100
If your intention is to round to the nearest ten, than the given example is correct
round(‘halfUp’, lumpSum/10)*10
Hope this helps.
Frank
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
14 | |
8 | |
6 | |
4 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.