sqlsrv_server_info

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

sqlsrv_server_infoReturns information about the server

说明

sqlsrv_server_info ( resource $conn ) : array

Returns information about the server.

参数

conn

The connection resource that connects the client and the server.

返回值

Returns an array as described in the following table:

Returned Array
CurrentDatabase The connected-to database.
SQLServerVersion The SQL Server version.
SQLServerName The name of the server.

范例

Example #1 sqlsrv_server_info() example

<?php
$serverName 
"serverName\sqlexpress";
$conn sqlsrv_connect$serverName);
if( 
$conn === false ) {
     die( 
print_rsqlsrv_errors(), true));
}

$server_info sqlsrv_server_info$conn);
if( 
$server_info )
{
    foreach( 
$server_info as $key => $value) {
       echo 
$key.": ".$value."<br />";
    }
} else {
      die( 
print_rsqlsrv_errors(), true));
}
?>

参见

相关文章
php date/time 函数 returns an array with information about sunset/sunrise and twilight begin/endphp gnupg 函数 returns an array with information about all keys that matches the given patternphp firebird/interbase 函数 request information about a database serverphp semaphore 函数 returns information from the message queue data structurephp mysqlnd memcache 函数 returns information about the plugin configurationphp odbc 函数 returns information about a current connectionphp odbc 函数 retrieves information about data types supported by the data sourcephp postgresql 函数 returns an array with client protocol and server version when available php paradox 函数 return lots of information about a paradox filephp rrd 函数 gets information about underlying rrdtool libraryphp sqlsrv 函数 returns information about the client and specified connectionphp sqlsrv 函数 returns error and warning information about the last sqlsrv operation performedphp sqlsrv 函数 returns information about the serverphp wincache 函数 retrieves information about files cached in the session cachephp hyperwave api 函数 returns statistics about database serverphp hyperwave api 函数 returns statistics about document cache serverphp hyperwave api 函数 returns statistics about fulltext serverphp hyperwave api 函数 returns statistics about hyperwave serverphp hyperwave api 函数 returns information about server configurationphp mongodb driver server returns an array of information about this server
关注编程学问公众号