Saving Float to Database

I have a database table that takes in an array of floats. it ls defined like this field(:scale, {:array, :float})

When I pass it with the value of [0,0,0] it converts it to [0.0, 0.0, 0.0]

That is all fine, its very important I store these values in this order and they can sometimes be zero.

But postgres is throwing this error

** (DBConnection.EncodeError) Postgrex expected an integer in -2147483648..2147483647, got 0.0. Please make sure the value you are passing matches the definition in your table or in your query or convert the value accordingly.

Is it possible to save zeros as floats or should I find a new approach?

Can you show the migration? It sorta sounds like your database is expecting integers.

I ended up going a completely different route, is there anyway to close or delete this post?