The mi_money_to_string() function

The mi_money_to_string() function creates a text (string) representation of a monetary value from the binary (internal) MONEY representation.

Syntax

mi_string *mi_money_to_string(money_data)
   mi_money *money_data;
money_data
A pointer to the internal MONEY representation of the monetary value.
Valid in client LIBMI application? Valid in user-defined routine?
Yes Yes

Usage

The mi_money_to_string() function converts the internal MONEY value that money_data contains into a monetary string. An internal MONEY value is the format that the database server uses to store a value in a MONEY column of the database.
Important: The mi_money_to_string() function replaces the mi_binary_to_money() function for internal MONEY-to-string conversion in DataBlade® API modules.

For GLS, the mi_money_to_string() function formats the monetary string in the monetary format of the current processing locale. For more information, see the HCL OneDB™ GLS User's Guide.

For more information about how to convert internal MONEY format to monetary strings, see the HCL OneDB DataBlade API Programmer's Guide.

Return values

An mi_string pointer
A pointer to the monetary string equivalent of money_data.
NULL
The function was not successful.