0

我将 PHP 5.2.9 和 Micorsoft SQL Server 2008 R2 与 Apache 一起使用,并且有这样的 PHP 代码行

<?php
$serverName = "xxx-xxxxxxxxxxx\xxx"
$connection = array("数据库"=>"示例");
$conn = sqlsrv_connect($serverName, $connection);

如果($conn)
{
     echo "连接建立。";
}
别的
{
     echo "无法建立连接。";
         打印_r($连接);
     死(print_r(sqlsrv_errors(),真));
}
?>

但它显示如下错误:

Connection could not be established.

Array ( [Database] => example )

Array ( [0] => Array ( [0] => IMSSP [SQLSTATE] => IMSSP [1] => -47 [code] => -47 [2] => An error occurred translating the connection string to UTF-16: No mapping for the Unicode character exists in the target multi-byte code page. [message] => An error occurred translating the connection string to UTF-16: No mapping for the Unicode character exists in the target multi-byte code page. ) )

对我的问题有什么建议吗?

4

0 回答 0