Application development in PHP (ibm_db2)
The ibm_db2 extension provides a variety of useful PHP
functions for accessing and manipulating data in an IBM data server database. The extension
includes functions for connecting to a database, executing and preparing
SQL statements, fetching rows from result sets, calling stored procedures,
handling errors, and retrieving metadata.
Connecting to an IBM data server database in PHP (ibm_db2)
You can use the ibm_db2 API to connect to an IBM data server database through either a cataloged connection or a direct TCP/IP connection.
Executing SQL statements in PHP (ibm_db2)
After connecting to a database, use functions available in the ibm_db2 API to prepare and execute SQL statements. The SQL statements can contain static text, XQuery expressions, or parameter markers that represent variable input.
Calling stored procedures in PHP (ibm_db2)
To call a stored procedure from a PHP application, you prepare and execute an SQL CALL statement. The procedure that you call can include input parameters (IN), output parameters (OUT), and input and output parameters (INOUT).
Commit modes in PHP applications (ibm_db2)
You can control how groups of SQL statements are committed by specifying a commit mode for a connection resource. The ibm_db2 extension supports two commit modes: autocommit and manual commit.
Error-handling functions in PHP applications (ibm_db2)
The ibm_db2 API provides error-handling functions to help you recover gracefully from the error situations.
Database metadata retrieval functions in PHP (ibm_db2)
You can use functions in the ibm_db2 API to retrieve metadata for databases served by Db2® , IBM® Cloudscape, and, through Db2 Connect , Db2 for z/OS® and Db2 for i .