Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
Does anybody ever seen this problem?
Expression:
num([Valor Conta 2],'0.0') - rangesum(num([Valor Recebido 2],'0.0'),num([Valor Glosa 2],'0.0'),num([Valor Perda 2],'0.0'),num([VL_PAGO_RETORNO 2],'0.0'),num([VL_GLOSADO_RETORNO 2],'0.0'))
or
2266,15 - (2142,24+123,91) = 4,54747350..... should be zero!
Maybe using round(). And no need for num() for each part, it is only for presentation but doesn't change underlying values.
round(
[Valor Conta 2] - rangesum([Valor Recebido 2], [Valor Glosa 2], [Valor Perda 2], [VL_PAGO_RETORNO 2], [VL_GLOSADO_RETORNO 2])
,0.01)
It is close enough to 0 - see this "e-013"
The problem is that I have some conditions that depend on this result.
Do you have any tips on how to fix this?
Maybe using round(). And no need for num() for each part, it is only for presentation but doesn't change underlying values.
round(
[Valor Conta 2] - rangesum([Valor Recebido 2], [Valor Glosa 2], [Valor Perda 2], [VL_PAGO_RETORNO 2], [VL_GLOSADO_RETORNO 2])
,0.01)
Hi,
Try rounding to something reasonable.
Round(num([Valor Conta 2],'0.0'),0.001) -Round(rangesum(num([Valor Recebido 2],'0.0'),num([Valor Glosa 2],'0.0'),num([Valor Perda 2],'0.0'),num([VL_PAGO_RETORNO 2],'0.0'),num([VL_GLOSADO_RETORNO 2],'0.0')),0.001)