Beispiel #1
0
 /**
  * Version information about used database
  * @param bool $raw if true, only return the fetched sql_server_version
  * @param bool $use_cache forced to false for Oracle
  * @return string sql server version
  */
 function sql_server_info($raw = false, $use_cache = true)
 {
     /**
      * force $use_cache false.  I didn't research why the caching code below is commented out
      * but I assume its because the Oracle extension provides a direct method to access it
      * without a query.
      */
     $use_cache = false;
     /*
     		global $cache;
     
     		if (empty($cache) || ($this->sql_server_version = $cache->get('oracle_version')) === false)
     		{
     			$result = @ociparse($this->db_connect_id, 'SELECT * FROM v$version WHERE banner LIKE \'Oracle%\'');
     			@ociexecute($result, OCI_DEFAULT);
     			@ocicommit($this->db_connect_id);
     
     			$row = array();
     			@ocifetchinto($result, $row, OCI_ASSOC + OCI_RETURN_NULLS);
     			@ocifreestatement($result);
     			$this->sql_server_version = trim($row['BANNER']);
     
     			$cache->put('oracle_version', $this->sql_server_version);
     		}
     */
     $this->sql_server_version = @ociserverversion($this->db_connect_id);
     return $this->sql_server_version;
 }
 /**
  *	This function will return the version of the database server software.
  *
  *	@returns	The version of the database server software.
  */
 function getServerVersion()
 {
     // Connect
     $result = $this->connect();
     // Handle errors
     if (!$result && $this->_failOnError === true) {
         $error = ocierror();
         trigger_error($error['message'], YD_ERROR);
     }
     // Return the version
     return 'Oracle ' . ociserverversion($this->_conn);
 }
Beispiel #3
0
 /**
  * Version information about used database
  * @param bool $raw if true, only return the fetched sql_server_version
  * @return string sql server version
  */
 function sql_server_info($raw = false)
 {
     /*
     		global $cache;
     
     		if (empty($cache) || ($this->sql_server_version = $cache->get('oracle_version')) === false)
     		{
     			$result = @ociparse($this->db_connect_id, 'SELECT * FROM v$version WHERE banner LIKE \'Oracle%\'');
     			@ociexecute($result, OCI_DEFAULT);
     			@ocicommit($this->db_connect_id);
     
     			$row = array();
     			@ocifetchinto($result, $row, OCI_ASSOC + OCI_RETURN_NULLS);
     			@ocifreestatement($result);
     			$this->sql_server_version = trim($row['BANNER']);
     
     			$cache->put('oracle_version', $this->sql_server_version);
     		}
     */
     $this->sql_server_version = @ociserverversion($this->db_connect_id);
     return $this->sql_server_version;
 }
Beispiel #4
0
  <td align="left"><?php 
echo function_exists('mysql_connect') ? '<b class="ok">' . $okImg . '</b><span class="item"> (' . @mysql_get_server_info() . ')</span>' : '<span class="warning">' . $failedImg . ' Not available</span>';
?>
</td>
</tr>
<tr>
 <td class="item"><li>ODBC Support</li></td>
  <td align="left"><?php 
echo function_exists('odbc_connect') ? '<b class="ok">' . $okImg . '</b><span class="item"></span>' : '<span class="warning">' . $failedImg . ' Not available</span>';
?>
</td>
</tr>
<tr>
 <td class="item"><li>Oracle Support</li></td>
  <td align="left"><?php 
echo function_exists('oci_connect') ? '<b class="ok">' . $okImg . '</b><span class="item"> (' . ociserverversion() . ')</span>' : '<span class="warning">' . $failedImg . ' Not available</span>';
?>
</td>
</tr>
<tr>
 <td class="item"><li>PostgreSQL Support</li></td>
  <td align="left"><?php 
echo function_exists('pg_connect') ? '<b class="ok">' . $okImg . '</b><span class="item"></span>' : '<span class="warning">' . $failedImg . ' Not available</span>';
?>
</td>
</tr>
<tr>
 <td class="item"><li>SQLite Support</li></td>
  <td align="left"><?php 
echo function_exists('sqlite_open') ? '<b class="ok">' . $okImg . '</b><span class="item"> (' . sqlite_libversion() . ')</span>' : '<span class="warning">' . $failedImg . ' Not available</span>';
?>
Beispiel #5
0
 /**
  * Version number query string
  *
  * @access  public
  * @return  string
  */
 function _version()
 {
     return ociserverversion($this->conn_id);
 }
 /**
  *	This function will return the version of the database server software.
  *
  *	@returns	The version of the database server software.
  */
 function getServerVersion()
 {
     $this->connect();
     return 'Oracle ' . ociserverversion($this->_conn);
 }
 /**
  * Version number query string
  *
  * @access  public
  * @return  string
  */
 function _version()
 {
     $ver = ociserverversion($this->conn_id);
     return $ver;
 }
Beispiel #8
0
 /**
  * Version information about used database
  */
 function sql_server_info()
 {
     return @ociserverversion($this->db_connect_id);
 }
Beispiel #9
0
 /**
  * return version information about the server
  *
  * @param bool   $native  determines if the raw version string should be returned
  * @return mixed array/string with version information or MDB2 error object
  * @access public
  */
 function getServerVersion($native = false)
 {
     $connection = $this->getConnection();
     if (PEAR::isError($connection)) {
         return $connection;
     }
     if ($this->connected_server_info) {
         $server_info = $this->connected_server_info;
     } else {
         $server_info = @ociserverversion($connection);
     }
     if (!$server_info) {
         return $this->raiseError(null, null, null, 'Could not get server information', __FUNCTION__);
     }
     // cache server_info
     $this->connected_server_info = $server_info;
     if (!$native) {
         if (!preg_match('/ (\\d+)\\.(\\d+)\\.(\\d+)\\.([\\d\\.]+) /', $server_info, $tmp)) {
             return $this->raiseError(MDB2_ERROR_INVALID, null, null, 'Could not parse version information:' . $server_info, __FUNCTION__);
         }
         $server_info = array('major' => $tmp[1], 'minor' => $tmp[2], 'patch' => $tmp[3], 'extra' => $tmp[4], 'native' => $server_info);
     }
     return $server_info;
 }
Beispiel #10
0
		<td><span class="warning">Not available</span></td>
	<?php 
}
?>
	</tr>
	<tr class="second">
		<td class="item"><li>Oracle Support</li></td>
	<?php 
if (function_exists('oci_connect')) {
    ?>
		<td align="left"><?php 
    echo $okImg;
    ?>
</td>
		<td><b class="message"><span class="item"> (<?php 
    echo ociserverversion();
    ?>
)</span></b></td>
	<?php 
} else {
    ?>
		<td align="left"><?php 
    echo $failedImg;
    ?>
</td>
		<td><span class="warning">Not available</span></td>
	<?php 
}
?>
	</tr>
	<tr class="second">
Beispiel #11
0
 public function getVersion()
 {
     return @ociserverversion($this->_hMaster);
 }
ocidefinebyname();
ocierror();
ociexecute();
ocifetch();
ocifetchinto();
ocifetchstatement();
ocifreecollection();
ocifreecursor();
ocifreedesc();
ocifreestatement();
ociinternaldebug();
ociloadlob();
ocilogoff();
ocilogon();
ocinewcollection();
ocinewcursor();
ocinewdescriptor();
ocinlogon();
ocinumcols();
ociparse();
ociplogon();
ociresult();
ocirollback();
ocirowcount();
ocisavelob();
ocisavelobfile();
ociserverversion();
ocisetprefetch();
ocistatementtype();
ociwritelobtofile();
ociwritetemporarylob();