db2_conn_error

PECL ibm_db2 >= 1.0.0
db2_conn_error - Returns a string containing the SQLSTATE returned by the last connection attempt
Manual
Code Examples

Example #1 Retrieving an SQLSTATE value for a failed connection attempt

Result: SQLSTATE value: 08001
PHP Version: