Scalar. Converts a given value to the appropriate money type, based on a given scale.
to_money ( value, scale )
value | A string, or a numeric type. The string must be all numeric, but can include a decimal point. |
scale | An integer from 1 to 15. |
Converts a given value to a money type, based on the given scale. The function takes a string or a numeric type as its argument, and the function returns a money.
to_money (12.361, 2)returns 12.36.