Jump to content

MSSQL 2005 EXPRESS, couldn't connect to server problem


Akulaari

Recommended Posts

Hi,

I'm having this same problem as many others do, but I just can't seem to get things working at all.

*I have copied ntwdblib.dll version 2000.80.194.0 to win/system32 and PHP directories

*extension=php_mssql.dll is uncommented in php.ini

*I'm using following php code to connect:

$server = "localhost\SQLEXPRESS";

$s = mssql_connect($server,$userName,$password) or die("Couldn't connect to SQL Server");

(of course I have given username and pw) but I just seem to get connection error.

*I have tried to connect to same database from command prompt with same username and password, and there it works. So the problem seems to exist only in PHP now.

*I have allowed tcp/ip and named pipes in SQL Server Configuration Manager.

 

Lastly I have found out that for someone with this problem working solution was to use the sqlsrv driver instead of mssql. However I haven't found sqlsrv driver in my php.ini so could anyone help me with that since it could solve this?

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.