The mi_binary_to_decimal() function
The mi_binary_to_decimal() function creates a text (string) representation of a decimal value from the internal (binary) DECIMAL representation.
Syntax
mi_lvarchar *mi_binary_to_decimal(decimal_data)
mi_decimal *decimal_data;
- decimal_data
- A pointer to the internal DECIMAL representation of the decimal value.
Valid in client LIBMI application? | Valid in user-defined routine? |
---|---|
Yes | Yes |
Usage
The mi_binary_to_decimal() function converts the internal DECIMAL value that decimal_data contains into a decimal string. It returns a pointer to the buffer that contains the resulting decimal string.
For GLS, the mi_binary_to_decimal() function formats the decimal string in the numeric format of the current processing locale. It also performs any code-set conversion necessary between the current processing locale and the target locale.
Important: The mi_binary_to_decimal() function
is supported only for compatibility with earlier versions of existing DataBlade®
API modules.
The DataBlade
API will
eventually discontinue support for this function. Use the mi_decimal_to_string() function
in any new DataBlade
API modules.
Return values
- An mi_lvarchar pointer
- A pointer to the decimal string that mi_binary_to_decimal() creates.
- NULL
- The function was not successful.