XP下PHP可以通过sqlsrv链接sql server2005http://tokyo2006.iteye.com/blog/762813
http://support.microsoft.com/kb/936302/zh-cn
http://blog.csdn.net/acsu/article/details/1744981
http://support.microsoft.com/kb/936302/zh-cn
http://blog.csdn.net/acsu/article/details/1744981
谢谢回答,但是你给的这三个连接都是讲win SERTVER 2008 啊,我服务器上确实可行了。现在就想我的主机XP上面是不是可以用sqlsrv扩展...
谢谢回答,但是你给的这三个连接都是讲win SERTVER 2008 啊,我服务器上确实可行了。现在就想我的主机XP上面是不是可以用sqlsrv扩展...
配置同理
Connection could not be established.
Array ( [0] => Array ( [0] => IMSSP [SQLSTATE] => IMSSP [1] => -49 [code] => -49 [2] => This extension requires either the Microsoft SQL Server 2008 Native Client (SP1 or later) or the Microsoft SQL Server 2008 R2 Native Client ODBC Driver to communicate with SQL Server. Neither of those ODBC Drivers are currently installed. Access the following URL to download the Microsoft SQL Server 2008 R2 Native Client ODBC driver for x86: http://go.microsoft.com/fwlink/?LinkId=163712 [message] => This extension requires either the Microsoft SQL Server 2008 Native Client (SP1 or later) or the Microsoft SQL Server 2008 R2 Native Client ODBC Driver to communicate with SQL Server. Neither of those ODBC Drivers are currently installed. Access the following URL to download the Microsoft SQL Server 2008 R2 Native Client ODBC driver for x86: http://go.microsoft.com/fwlink/?LinkId=163712 ) [1] => Array ( [0] => IM002 [SQLSTATE] => IM002 [1] => 0 [code] => 0 [2] => [Microsoft][ODBC 驱动程序管理器] 未发现数据源名称并且未指定默认驱动程序 [message] => [Microsoft][ODBC 驱动程序管理器] 未发现数据源名称并且未指定默认驱动程序 ) ) 还是这个问题可能是我设置有问题?
extension=php_pdo_sqlsrv_52_ts_vc6.dll
extension=php_sqlsrv_52_ts_vc6.dll
extension=php_pdo.dll
php.ini里面添加了这三条还有哪里不对?
Connection could not be established.
Array ( [0] => Array ( [0] => IMSSP [SQLSTATE] => IMSSP [1] => -49 [code] => -49 [2] => This extension requires either the Microsoft SQL Server 2008 Native Client (SP1 or later) or the Microsoft SQL Server 2008 R2 Native Client ODBC Driver to communicate with SQL Server. Neither of those ODBC Drivers are currently installed. Access the following URL to download the Microsoft SQL Server 2008 R2 Native Client ODBC driver for x86: http://go.microsoft.com/fwlink/?LinkId=163712 [message] => This extension requires either the Microsoft SQL Server 2008 Native Client (SP1 or later) or the Microsoft SQL Server 2008 R2 Native Client ODBC Driver to communicate with SQL Server. Neither of those ODBC Drivers are currently installed. Access the following URL to download the Microsoft SQL Server 2008 R2 Native Client ODBC driver for x86: http://go.microsoft.com/fwlink/?LinkId=163712 ) [1] => Array ( [0] => IM002 [SQLSTATE] => IM002 [1] => 0 [code] => 0 [2] => [Microsoft][ODBC 驱动程序管理器] 未发现数据源名称并且未指定默认驱动程序 [message] => [Microsoft][ODBC 驱动程序管理器] 未发现数据源名称并且未指定默认驱动程序 ) ) 还是这个问题可能是我设置有问题?
extension=php_pdo_sqlsrv_52_ts_vc6.dll
extension=php_sqlsrv_52_ts_vc6.dll
extension=php_pdo.dll
php.ini里面添加了这三条还有哪里不对?
确定加入的dll版本是否有误。
Connection could not be established.
Array ( [0] => Array ( [0] => IMSSP [SQLSTATE] => IMSSP [1] => -49 [code] => -49 [2] => This extension requires either the Microsoft SQL Server 2008 Native Client (SP1 or later) or the Microsoft SQL Server 2008 R2 Native Client ODBC Driver to communicate with SQL Server. Neither of those ODBC Drivers are currently installed. Access the following URL to download the Microsoft SQL Server 2008 R2 Native Client ODBC driver for x86: http://go.microsoft.com/fwlink/?LinkId=163712 [message] => This extension requires either the Microsoft SQL Server 2008 Native Client (SP1 or later) or the Microsoft SQL Server 2008 R2 Native Client ODBC Driver to communicate with SQL Server. Neither of those ODBC Drivers are currently installed. Access the following URL to download the Microsoft SQL Server 2008 R2 Native Client ODBC driver for x86: http://go.microsoft.com/fwlink/?LinkId=163712 ) [1] => Array ( [0] => IM002 [SQLSTATE] => IM002 [1] => 0 [code] => 0 [2] => [Microsoft][ODBC 驱动程序管理器] 未发现数据源名称并且未指定默认驱动程序 [message] => [Microsoft][ODBC 驱动程序管理器] 未发现数据源名称并且未指定默认驱动程序 ) ) 还是这个问题可能是我设置有问题?
extension=php_pdo_sqlsrv_52_ts_vc6.dll
extension=php_sqlsrv_52_ts_vc6.dll
extension=php_pdo.dll
php.ini里面添加了这三条还有哪里不对?
确定加入的dll版本是否有误。
phpinfo()查看sqlstr扩展是否开启,确定sqlserver开启远程连接。
你配置的只是 sqlsrv 的 php 扩展,而要使这个扩展工作起来还需要相应的客户端或ODBC才行
sqlsrv support enabled
pdo_sqlsrv support enabled PDO drivers sqlite, firebird, mssql, mysql, odbc, pgsql, sqlsrv
Registered PHP Streams php, file, data, http, ftp, compress.zlib, sqlsrv
貌似都开了啊
2、错误信息中也给出了下载地址