The mi_get_double_precision() function

The mi_get_double_precision() function copies an mi_double_precision (FLOAT) value, converting any difference in alignment or byte order on the client computer to that of the server computer.

Syntax

mi_unsigned_char1 *mi_get_double_precision(data_ptr, dbl_ptr)
   mi_unsigned_char1 *data_ptr;
   mi_double_precision *dbl_ptr;
data_ptr
A pointer to the buffer from which to copy the mi_double_precision value.
dbl_ptr
A pointer to the buffer to which to copy the mi_double_precision value.
Valid in client LIBMI application? Valid in user-defined routine?
No Yes

Usage

The mi_get_double_precision() function copies a value from the user-defined buffer that data_ptr references into the buffer that dbl_ptr references. Upon completion, mi_get_double_precision() returns the address of the next position from which data can be copied from the data_ptr buffer. The function returns the data_ptr address advanced by n bytes, ready for a subsequent copy. In other words, if n is the length of the value that dbl_ptr indicates, the returned address is advanced n bytes from the original buffer address in data_ptr.

The mi_get_double_precision() function is useful in a receive support function of an opaque data type that contains an mi_double_precision value. Use this function to receive an mi_double_precision field of an opaque-type internal structure from a client application (which possibly has unaligned data buffers).

For more information about the use of mi_get_double_precision() in a receive support function, see the Informix® DataBlade® API Programmer's Guide.

Return values

An mi_unsigned_char1 pointer
The new address in the data_ptr data buffer.
NULL
The function was not successful.