skip to main content
IP API Reference for C/C++ : IP API for C/C++ : OASQLIP_error
 

OASQLIP_error

This function returns the error during the last IP operation. If one or more errors are available, it returns one error and clears the rest. When the error is returned, the function deletes the error from the list of errors on the specified statement or connection. If no errors are available, the function returns OADS_NO_DATA to indicate no more errors are present.
int OASQLIP_error(
SQLIP_HDBC sqlip_hdbc,
SQLIP_HSTMT sqlip_hstmt,
OAWCHAR * sSqlState,
OADS_INTEGER * piNativeError,
OAWCHAR * sErrorText)
 
Table 15: Parameters for OASQLIP_error 
Parameter
Type
Description
INPUT
 
 
sqlip_hdbc
SQLIP_HDBC
Connection handle.
sqlip_hstmt
SQLIP_HSTMT
Statement handle.
OUTPUT
 
 
sSqlState
OAWCHAR *
SQL state string if sSqlState is not NULL. If NULL, an empty string.
piNativeError
OADS_INTEGER  *
Integer value indicating a native error. This code is made available to the client application. Provide this if piNativeError is not NULL.
sErrorText
OAWCHAR *
Error message of length SQLDRV_MAX_MESSAGE_LENGTH or less if sErrorText is not NULL. An empty string if no errors available.
RETURN
 
 
 
int
OADS_SUCCESS - error is being returned
OADS_NO_DATA – no errors available
OADS_ERROR – error processing error request