I want to use the numeric type of Postgresql 9.3 but my parser :
private val Account403Parser: RowParser[Account403] = {
get[Long]("id") ~
get[Float]("amount") map {
case id ~ amount =>
Account403.apply(id, amount)
}
doesn't work since anorm can't convert from java.math.BigDecimal to Float.
Here is the error that I get :
[RuntimeException: TypeDoesNotMatch(Cannot convert 9.5: class java.math.BigDecimal to Float for column ColumnName(account403.amount,Some(amount)))]
How can I change my parser to make it convert from the java.math.BigDecimal type to the Float type?