Here is what I’m setting:
result = price / (case when tax = 0 then @tax1h / 100 else @tax2 / 100 end + 1)
These are the values:
price = 17.5
tax = 1
tax2 = 6
17.5 / (6 / 100 + 1) = 16.5
And this returns 17.5 Why is this happening and how to solve it?
Integer division:
The result of the above is 1.
However, the result of:
Is 1.06.