MySQL Connector/C++ 9.1.0
MySQL connector library for C and C++ applications
Functions
Diagnostics

Functions

mysqlx_error_tmysqlx_error (void *obj)
 Get the last error from the object. More...
 
const char * mysqlx_error_message (void *obj)
 Get the error message from the object. More...
 
unsigned int mysqlx_error_num (void *obj)
 Get the error number from the object. More...
 
unsigned int mysqlx_result_warning_count (mysqlx_result_t *res)
 Get the number of warnings generated by a statement. More...
 
mysqlx_error_tmysqlx_result_next_warning (mysqlx_result_t *res)
 Get the next warning from the result. More...
 

Detailed Description

Function Documentation

◆ mysqlx_error()

mysqlx_error_t * mysqlx_error ( void *  obj)

Get the last error from the object.

Parameters
objhandle to the object to extract the error information from. Supported handle types are mysqlx_session_t, mysqlx_session_options_t, mysqlx_schema_t, mysqlx_collection_t, mysqlx_table_t, mysqlx_stmt_t, mysqlx_result_t, mysqlx_row_t, mysqlx_error_t
Returns
the error handle or NULL if there is no errors.

◆ mysqlx_error_message()

const char * mysqlx_error_message ( void *  obj)

Get the error message from the object.

Parameters
objhandle to the object to extract the error information from. Supported handle types are mysqlx_session_t, mysqlx_session_options_t, mysqlx_schema_t, mysqlx_collection_t, mysqlx_table_t, mysqlx_stmt_t, mysqlx_result_t, mysqlx_row_t, mysqlx_error_t
Returns
the character string or NULL if there is no errors.

◆ mysqlx_error_num()

unsigned int mysqlx_error_num ( void *  obj)

Get the error number from the object.

Parameters
objhandle to the object to extract the error information from. Supported handle types are mysqlx_session_t, mysqlx_session_options_t, mysqlx_schema_t, mysqlx_collection_t, mysqlx_table_t, mysqlx_stmt_t, mysqlx_result_t, mysqlx_row_t, mysqlx_error_t
Returns
the error number or 0 if no error

◆ mysqlx_result_warning_count()

unsigned int mysqlx_result_warning_count ( mysqlx_result_t res)

Get the number of warnings generated by a statement.

Parameters
resresult handle
Returns
the number of warnings stored in the result

◆ mysqlx_result_next_warning()

mysqlx_error_t * mysqlx_result_next_warning ( mysqlx_result_t res)

Get the next warning from the result.

This function returns a handle to a warning which can be examined using the same functions used for errors: mysqlx_error_num() and mysqlx_error_message().

Parameters
resresult handle
Returns
handle to the next warning from the result or NULL if there is no more warnings left to return.
Note
The warning handle returned by a previous call is invalidated.