September 2, 2021 at 2:23 am
Actually, Sergiy, for certain calcs -- such as computing interest on a house loan in some places -- it's illegal to use more than 4 digits of accuracy.
So, if the data type is currency (money), use that type to do the calcs, period, just to be safe.
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
September 2, 2021 at 4:20 am
Actually, Sergiy, for certain calcs -- such as computing interest on a house loan in some places -- it's illegal to use more than 4 digits of accuracy.
So, if the data type is currency (money), use that type to do the calcs, period, just to be safe.
In New Zealand mortgage repayments are always rounded up to a whole dollar.
Rounded.
It does not mean they use integer math to calculate those repayments.
They just round the result of floating point calculations and adjust the final payment.
_____________
Code for TallyGenerator
September 3, 2021 at 2:15 pm
ScottPletcher wrote:Actually, Sergiy, for certain calcs -- such as computing interest on a house loan in some places -- it's illegal to use more than 4 digits of accuracy.
So, if the data type is currency (money), use that type to do the calcs, period, just to be safe.
In New Zealand mortgage repayments are always rounded up to a whole dollar.
Rounded.
It does not mean they use integer math to calculate those repayments. They just round the result of floating point calculations and adjust the final payment.
Most of the world is not in New Zealand.
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
September 3, 2021 at 2:51 pm
Sergiy wrote:ScottPletcher wrote:Actually, Sergiy, for certain calcs -- such as computing interest on a house loan in some places -- it's illegal to use more than 4 digits of accuracy.
So, if the data type is currency (money), use that type to do the calcs, period, just to be safe.
In New Zealand mortgage repayments are always rounded up to a whole dollar.
Rounded.
It does not mean they use integer math to calculate those repayments. They just round the result of floating point calculations and adjust the final payment.
Most of the world is not in New Zealand.
did you even try to understand my point?
_____________
Code for TallyGenerator
Viewing 4 posts - 16 through 18 (of 18 total)
You must be logged in to reply to this topic. Login to reply