array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'de', ), 'this' => array ( 0 => 'function.sqlsrv-client-info.php', 1 => 'sqlsrv_client_info', 2 => 'Returns information about the client and specified connection', ), 'up' => array ( 0 => 'ref.sqlsrv.php', 1 => 'SQLSRV Funktionen', ), 'prev' => array ( 0 => 'function.sqlsrv-cancel.php', 1 => 'sqlsrv_cancel', ), 'next' => array ( 0 => 'function.sqlsrv-close.php', 1 => 'sqlsrv_close', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'en', 'path' => 'reference/sqlsrv/functions/sqlsrv-client-info.xml', ), 'history' => array ( ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); contributors($setup); ?>

sqlsrv_client_info

(No version information available, might only be in Git)

sqlsrv_client_infoReturns information about the client and specified connection

Beschreibung

sqlsrv_client_info(resource $conn): array

Returns information about the client and specified connection

Parameter-Liste

conn

The connection about which information is returned.

Rückgabewerte

Returns an associative array with keys described in the table below. Returns false otherwise.
Array returned by sqlsrv_client_info
Key Description
DriverDllName SQLNCLI10.DLL
DriverODBCVer ODBC version (xx.yy)
DriverVer SQL Server Native Client DLL version (10.5.xxx)
ExtensionVer php_sqlsrv.dll version (2.0.xxx.x)

Beispiele

Beispiel #1 sqlsrv_client_info() example

<?php
$serverName
= "serverName\sqlexpress";
$connOptions = array("UID"=>"username", "PWD"=>"password");
$conn = sqlsrv_connect( $serverName, $connOptions );

if(
$conn === false ) {
die(
print_r( sqlsrv_errors(), true));
}

if(
$client_info = sqlsrv_client_info( $conn)) {
foreach(
$client_info as $key => $value) {
echo
$key.": ".$value."<br />";
}
} else {
echo
"Error in retrieving client info.<br />";
}
?>

Siehe auch