Function mz_repr::adt::numeric::numeric_to_twos_complement_wide
source · pub fn numeric_to_twos_complement_wide(numeric: Numeric) -> [u8; 33]
Expand description
Converts an Numeric
into a big endian two’s complement representation where
the encoded value has NUMERIC_AGG_MAX_PRECISION
digits and a scale of
NUMERIC_DATUM_MAX_PRECISION
.
This representation is appropriate to use in
contexts requiring two’s complement representation but Numeric
values’ scale
isn’t known, e.g. when working with columns with an explicitly defined
scale.