PHP and MSSQL and IIS

First you need to enable IIS in windows vista, through enable windows features in control panel. make sure to enable ISAPI and CGI as they are required for PHP fastcgi mode,

also to to be able to use mssql server with PHP under IIS you need to have SQLServerDriverForPHP11 installed, after downloading and installing this file, you will have a few dll files, which you need to copy them into php/ext folder and enable this in php.ini file.

extension=php_sqlsrv_52_nts_vc6.dll

Posted in Database, Programming | 1 Comment

Attaching Microsoft SQL database

Problem when attaching a microsoft SQL database.

When transferring a database form one pc to an other pc, or have copied the microsoft database files, and you want to attach them to the database, I had a problem and Microsoft Managment Studio was saying cannot read the file, while the file was there,

Problem: Sql server did not have the permission to access the file

Solution: give NETWORK SERVICES permission to those files,

Posted in Database | Leave a comment