EXACTNUMERIC and Rounding of Digits
Posted: Mon Aug 20, 2007 4:36 am
Hi,
Initially my problem was with arithmetic operations of number with larger singinifcant number of digits, but this was solved by using string mathematics functions.
But now, I also need to use FIX function to round of to 2 digits.
eg. Original Function: FIX(Input.FOREIGN_AMOUNT*(Input.RATE_MULT/Input.RATE_DIV),2,0) and after switching to String maths, the function is FIX(SMUL(Input.AMT,SDIV(Input.RATE_DID,Input.RATE_MULT)),2,0)
Now, using SMUL and SDIV have solved my problem of handling large numbes, but FIX is becoming a bottleneck, as it is rounding off the digits after 16th position. I have changed EXACTNUMERIC to variuos values say, 28, 36 and 57, but no change !!
The stes follwed for changing the EXACTNUMERIC were:
1. Logoff all users from DS
2. Edit uvconfig, and change EXACTNUMERIC to a new value
3. uvregen
4. Restart DS
5. uvregen -t ( It reflects the changes being applied)
Please advice
Initially my problem was with arithmetic operations of number with larger singinifcant number of digits, but this was solved by using string mathematics functions.
But now, I also need to use FIX function to round of to 2 digits.
eg. Original Function: FIX(Input.FOREIGN_AMOUNT*(Input.RATE_MULT/Input.RATE_DIV),2,0) and after switching to String maths, the function is FIX(SMUL(Input.AMT,SDIV(Input.RATE_DID,Input.RATE_MULT)),2,0)
Now, using SMUL and SDIV have solved my problem of handling large numbes, but FIX is becoming a bottleneck, as it is rounding off the digits after 16th position. I have changed EXACTNUMERIC to variuos values say, 28, 36 and 57, but no change !!
The stes follwed for changing the EXACTNUMERIC were:
1. Logoff all users from DS
2. Edit uvconfig, and change EXACTNUMERIC to a new value
3. uvregen
4. Restart DS
5. uvregen -t ( It reflects the changes being applied)
Please advice