pub fn munge_numeric(n: &mut Numeric) -> Result<(), Error>
Expand description

Ensures Numeric values are:

  • Within Numeric’s max precision (NUMERIC_DATUM_MAX_PRECISION), or errors if not.
  • Never possible but invalid representations (i.e. never -Nan or -0).

Should be called after any operation that can change an Numeric’s scale or generate negative values (except addition and subtraction).