Free a row descriptor
A row descriptor has the current memory duration. A row descriptor
remains valid until one of the following events occurs:
- The mi_row_desc_free() function frees the row.
- The current memory duration expires. (Server only)
- The mi_close() function closes the current connection.
To conserve resources, use the mi_row_desc_free() function to explicitly deallocate the row descriptor once your DataBlade API module no longer needs it. The mi_row_desc_free() function is the destructor function for a row descriptor. It frees the row descriptor and any resources that are associated with it.
Server only: In a C UDR, the row structure
and row descriptor are part of the same data type structure. The mi_row_create() function
just adds a data buffer, which holds the column values of a row, to
the row descriptor. The mi_row_desc_free() function
frees a row descriptor and the associated row structure. After mi_row_desc_free() frees
the row descriptor, you no longer have access to the row structure.
Client only: In a client LIBMI application,
a row structure and a row descriptor are separate data type structures.
When you free a row descriptor with mi_row_desc_free(),
the associated row structure is not freed. You must explicitly free
the row structure with mi_row_free().
Important: Use mi_row_desc_free() only
for row descriptors that you have explicitly allocated with mi_row_desc_create().
Do not use this function to free row structures that other DataBlade
API functions
(such as mi_get_row_desc_without_row()) allocate.