After passing the material number into a customized function module I am getting the output value in numerical format.
After getting that result I need to do the following operation on it
If the output has more than 2 decimal places then the value must be trimmed
If the output has 2 decimal places then the value must be showed alike
Here are the samples
4.6 % should be converted to 4.60 %
43 % should be converted to 43.00 %
16.325 % should be converted to 16.32 %
By using below code.Let variable be lv_variable.
data: lv_var type p decimals 2.
lv_var = lv_variable.
it worked only 1f we will pass the values like 12.22,3.65,2.5555
but if the value is 12.6999 means the value is we get the output as 12.70,But I need to get the value as 12.69 only but not 12.70