@katie You can’t use floats for money because 2.3 - 0.3 = 1.99999999999 in floating point logic
“Decimal” types solve this by storing the value as integers internally
Using integers directly works when you also store the currency, and keep a table of the currency’s exponent, eg https://github.com/elixirmoney/money/blob/master/lib/money/currency.ex
I prefer this way because then I don’t have to worry about the database representation, or what happens to the value in a JSON API.