Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi, Expert:
When we use function round, we found a strange status:
= ROUND(26364461.43,0.1) | = 26364461.4 |
= ROUND(26364461.44,0.1) | = 26364461.4 |
But when the number is 26364461.45 , the answer become 26364461.4, In my mind, it should be 26364461.5.
= ROUND(26364461.45,0.1) | = 26364461.4 |
When we use the follow number , 26364461.46, 26364461.47 the answer is correct "26364461.5"
= ROUND(26364461.46,0.1) | = 26364461.5 |
= ROUND(26364461.47,0.1) | = 26364461.5 |
so, is ROUND(26364461.45,0.1) = 26364461.4 correct ?
I'm using Qlikview x64 11.20.SR9 Desktop.
Many thnaks
Kent
:
Hi, Jonathan:
How do I get provided to access this link --
num() rounds differently to round() for half-step values
http://community.qlik.com/message/423596#423596
or
have any workaround solution ?
Many thanks.
Kent Liao
This provides better context on the inconsistencies.
http://community.qlik.com/blogs/qlikviewdesignblog/2013/12/17/rounding-errors
The suggestion is to avoid rounding to sub-integer fractions. Like rounding to .5 or .6 etc...
In your case, instead of rounding to a sub-integer fraction, multiply by 10 and round to an integer, than divide by 10 as follows:
= ROUND(26364461.45 * 10) / 10
HI, Manojqlik & Jonathan:
Thanks a lot, I'll try it.
by the way, is this Bug possible to fix, when?
Best Regards...
Kent Liao
Hi kent,
that we need to ask qliktech, but i am not sure how much time it takes,
pls make this thread close