|
The mi_query_finish() function finishes execution of the current statement.
conn | is a pointer to the connection descriptor that a previous call to mi_open(), mi_server_connect(), or mi_server_reconnect() has established. |
The mi_query_finish() function completes execution of the current statement on the connection that conn references. The current statement is the most recently executed SQL statement sent to the database server on that connection. This function performs the following steps:
The mi_query_finish() function does not affect prepared statements or calls to DataBlade API file-access functions. To determine whether the current statement has completed execution, use the mi_command_is_finished() function.
After mi_query_finish() executes, the next iteration of the mi_get_result() function returns a status of MI_NO_MORE_RESULTS.
This function is useful for ensuring that a statement that returns no meaningful results, such as BEGIN WORK, executed successfully.
MI_OK | indicates that the function was successful. |
MI_ERROR | indicates that the function was not successful, the current statement failed, or no statement is being processed. |
See the descriptions of the following functions: mi_command_is_finished(), mi_server_connect(), mi_get_result(), and mi_query_interrupt().
For more information, see Finishing Execution.