25 #require_once 'Zend/Db/Adapter/Pdo/Abstract.php'; 28 #require_once 'Zend/Db/Adapter/Pdo/Ibm/Db2.php'; 31 #require_once 'Zend/Db/Adapter/Pdo/Ibm/Ids.php'; 34 #require_once 'Zend/Db/Statement/Pdo/Ibm.php'; 98 if ($this->_connection) {
106 if ($this->_serverType ===
null) {
107 $server = substr($this->
getConnection()->getAttribute(PDO::ATTR_SERVER_INFO), 0, 3);
132 }
catch (PDOException $e) {
134 #require_once 'Zend/Db/Adapter/Exception.php'; 135 $error = strpos($e->getMessage(),
'driver does not support that attribute');
137 throw new Zend_Db_Adapter_Exception(
"PDO_IBM driver extension is downlevel. Please use driver release version 1.2.1 or later", 0, $e);
154 if (array_key_exists(
'host', $this->_config)) {
155 $dsn =
';DATABASE=' . $this->_config[
'dbname']
156 .
';HOSTNAME=' . $this->_config[
'host']
157 .
';PORT=' . $this->_config[
'port']
159 .
';PROTOCOL=' .
'TCPIP;';
162 $dsn = $this->_config[
'dbname'];
164 return $this->_pdoType .
': ' . $dsn;
176 parent::_checkRequiredOptions(
$config);
178 if (array_key_exists(
'host', $this->_config) &&
179 !array_key_exists(
'port',
$config)) {
181 #require_once 'Zend/Db/Adapter/Exception.php'; 197 $stmt =
new $stmtClass($this, $sql);
198 $stmt->setFetchMode($this->_fetchMode);
210 return $this->_serverType->listTables();
245 return $this->_serverType->describeTable(
$tableName, $schemaName);
261 if (is_array($bind)) {
269 return parent::insert(
$table, $newbind);
283 return $this->_serverType->limit($sql,
$count, $offset);
301 $sequenceName .=
"_$primaryKey";
303 $sequenceName .=
'_seq';
321 return $this->_serverType->lastSequenceId($sequenceName);
334 return $this->_serverType->nextSequenceId($sequenceName);
345 $stmt = $this->
query(
'SELECT service_level, fixpack_num FROM TABLE (sysproc.env_get_inst_info()) as INSTANCEINFO');
349 if (preg_match(
'/((?:[0-9]{1,2}\.){1,3}[0-9]{1,2})/',
$result[0][0], $matches)) {
356 }
catch (PDOException $e) {
const ATTR_STRINGIFY_FETCHES
describeTable($tableName, $schemaName=null)
limit($sql, $count, $offset=0)
lastSequenceId($sequenceName)
_checkRequiredOptions(array $config)
nextSequenceId($sequenceName)
insert($table, array $bind)
lastInsertId($tableName=null, $primaryKey=null)
query($sql, $bind=array())
if(!isset($_GET['name'])) $name