In fact installing the mssql modules in php is easy, we may get errors sometimes. In phpinfo() it may be shown that the php mssql module is installed. But when we tried to connect to an SQL server through php script we will get error ” sorry something went wrong”
IF we need to install php mssql module it requires two DLLs php_mssql.dll and ntwdblib.dll. If these DLLs are not present in your php installation folder you need to download it. Copy these DLLs to php extension folder also copy ntwdblib.dll to system32 folder . Once you have done these, simply enable the module in php.ini file by uncommenting the line ;extension=php_mssql.dll. The line should be looked like
extension=php_mssql.dll
If there is no such line in php.ini, just add the above line just below the ” Dynamic Extensions ”
Once you did it, just restart apache server and it will be fine.
Common Error: the module mssql is shown in phpinfo, but mssql connections are not working
Solution : This is due to the version of ntwdblib.dll. You can download the latest version of this dll
(http://www.dlldll.com/ntwdblib.dll_download.html)




January 20th, 2010
Aneesh
Posted in
Tags: 

This stupid official files & docs never work !!
this is helpful….Thanks much man…
Many of the problems that occur with the mssql driver for SQL Server can be avoided by using the driver that is produced by Microsoft (which is supported by Microsoft and is commonly called the sqlsrv driver, for the prefix used in the API). The download for the driver is here:
http://www.microsoft.com/downloads/details.aspx?displaylang=en&FamilyID=ccdf728b-1ea0-48a8-a84a-5052214caad9
The source code is available here: http://www.codeplex.com/SQLSRVPHP
-Brian
Thanks Brian.. it will definitely help us
Hi Brian,
Actually I have first tried this “SQL Server Driver for PHP 1.1 – October 2009″ but that didn’t work without this ntwdblib.dll version 2000.80.194.0
Thanks
Sathyan
I certainly like your web site layout it’s so clean, simple to read.