sasql_errorcode

Returns the error code of the most-recently executed SAP Sybase IQ PHP function. Error codes are stored per connection. If no $conn is specified, then sasql_errorcode returns the last error code where no connection was available. For example, if you are calling sasql_connect and the connection fails, then call sasql_errorcode with no parameter for the $conn to get the error code. To get the corresponding error message use the sasql_error function

Prototype

int sasql_errorcode( [ sasql_conn $conn ] )

Parameters

$conn – The connection resource returned by a connect function.

Returns

An integer representing an error code. An error code of 0 means success. A positive error code indicates success with warnings. A negative error code indicates failure.