当前位置: 首页>>代码示例>>PHP>>正文


PHP db2_server_info函数代码示例

本文整理汇总了PHP中db2_server_info函数的典型用法代码示例。如果您正苦于以下问题:PHP db2_server_info函数的具体用法?PHP db2_server_info怎么用?PHP db2_server_info使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了db2_server_info函数的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: getCurrentSchema

 /**
  * {@inheritDoc}
  */
 public function getCurrentSchema()
 {
     if (!$this->isConnected()) {
         $this->connect();
     }
     $info = db2_server_info($this->resource);
     return isset($info->DB_NAME) ? $info->DB_NAME : '';
 }
开发者ID:CHRISTOPHERVANDOMME,项目名称:zf2complet,代码行数:11,代码来源:Connection.php

示例2: getQuoteIdentifierSymbol

 /**
  * @return string
  */
 public function getQuoteIdentifierSymbol()
 {
     $this->_connect();
     $info = db2_server_info($this->_connection);
     $identQuote = $info->IDENTIFIER_QUOTE_CHAR;
     return $identQuote;
 }
开发者ID:jorgenils,项目名称:zend-framework,代码行数:10,代码来源:Db2.php

示例3: getServerVersion

 /**
  * Retrieve server version in PHP style
  *
  * @return string
  */
 public function getServerVersion()
 {
     $this->_connect();
     $server_info = db2_server_info($this->_connection);
     if ($server_info !== false) {
         $version = $server_info->DBMS_VER;
         if ($this->_isI5) {
             $version = (int) substr($version, 0, 2) . '.' . (int) substr($version, 2, 2) . '.' . (int) substr($version, 4);
         }
         return $version;
     } else {
         return null;
     }
 }
开发者ID:conectapb,项目名称:sysagroweb,代码行数:19,代码来源:Db2.php

示例4: getServerVersion

 /**
  * @return string Version information from the database
  */
 public function getServerVersion()
 {
     $info = db2_server_info($this->mConn);
     return $info->DBMS_VER;
 }
开发者ID:nischayn22,项目名称:mediawiki-core,代码行数:8,代码来源:DatabaseIbm_db2.php

示例5: quoteIdentifier

 /**
  * Quotes an identifier.
  *
  * @param string $ident The identifier.
  * 
  * @return string The quoted identifier.
  */
 public function quoteIdentifier($string)
 {
     $info = db2_server_info($this->_connection);
     $identQuote = $info->IDENTIFIER_QUOTE_CHAR;
     return $identQuote . $string . $identQuote;
 }
开发者ID:jorgenils,项目名称:zend-framework,代码行数:13,代码来源:Db2.php

示例6: getDbInfo

 public function getDbInfo()
 {
     $this->getDatabase();
     $server = @db2_server_info($this->database);
     if (is_object($server)) {
         $server = get_object_vars($server);
     } else {
         $server = null;
     }
     $client = @db2_client_info($this->database);
     if (is_object($client)) {
         $client = get_object_vars($client);
     } else {
         $client = null;
     }
     return array("IBM DB2 Client Info" => $client, "IBM DB2 Server Info" => $server);
 }
开发者ID:jglaine,项目名称:sugar761-ent,代码行数:17,代码来源:IBMDB2Manager.php

示例7: getSchema

 public function getSchema()
 {
     $server = db2_server_info($this->_db->getConnection());
     return $server->DB_NAME;
 }
开发者ID:jorgenils,项目名称:zend-framework,代码行数:5,代码来源:Db2.php

示例8: server_version

 /**
  * This function returns the version string.
  *
  * @access  public
  * @author  Thorsten Rinne <thorsten@phpmyfaq.de>
  * @since   2005-04-16
  */
 function server_version()
 {
     $server = db2_server_info($this->conn);
     $ver = $server->DBMS_NAME . ' ' . $server->DBMS_VER;
     return $ver;
 }
开发者ID:nosch,项目名称:phpMyFAQ,代码行数:13,代码来源:Ibm_db2.php

示例9: getPrimaryKey

 public static function getPrimaryKey($table, $conn, $dbtype)
 {
     /**
      * Discover metadata information about this table.
      */
     $server_info = db2_server_info($conn);
     // $server_info->DBMS_NAME == "QSQ" is iSeries / i5
     if ($server_info->DBMS_NAME == "QSQ") {
         $sql = "SELECT column_name as colname FROM qsys2.syskeycst ";
         $sql .= "WHERE system_table_name = '" . $table . "' and ordinal_position > 0 order by ordinal_position asc";
     } else {
         $sql = "SELECT colname FROM SYSCAT.COLUMNS WHERE TABNAME = '" . $table . "' AND KEYSEQ > 0 ORDER BY KEYSEQ ASC";
     }
     $rs = self::query($conn, $sql);
     if ($rs) {
         $res = self::fetch_num($rs);
         self::closeCursor($rs);
         if ($res) {
             return $res[0];
         }
     }
     return false;
 }
开发者ID:Russell-IO,项目名称:php-syslog-ng,代码行数:23,代码来源:jqGridDb2.php


注:本文中的db2_server_info函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。