|
The mi_get_result() function returns the status 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_get_result() function provides the statement status for 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. One of the DataBlade API statement-execution functions sent the statement to the database server: mi_exec(), mi_exec_prepared_statement(), or mi_open_prepared_statement().
The mi_get_result() function classifies SQL statements as follows.
The mi_get_result() function is typically executed in a loop that terminates when this function returns MI_NO_MORE_RESULTS. If mi_get_result() returns MI_ROWS, a query has executed and a cursor is ready to be accessed by the mi_next_row() function.
See the descriptions of the following functions: mi_exec(), mi_exec_prepared_statement(), mi_fetch_statement(), mi_next_row(), mi_open_prepared_statement(), mi_result_command_name(), and mi_result_row_count().
For more information about obtaining results, see Processing Statement Results.