Sunday, February 08, 2009

Abyss and Sql Server 2008

You might be wondering how hard it is to get php and SQL Server 2008 talking to each other on an abyss web server. Turns out it is pretty easy. Here are the basics (which is pretty much exactly how you think you would do it). Below assumes you already have Abyss, php, and sql server up and running.

1. Download and "install" (unpack into a folder) the latest php/SQL Server driver (it says 2005, works wth 2008, but you have to get funky if you want to use some of the new 2008 data types...update in the works).

2) Copy the php_sqlsrv_ts.dll from your driver's install folder into your php folder.

3) (Optional: Back up your php.ini file in your php folder, then...) Add the following line into the extensions section of your php.ini file-


4) Restart Abyss, and you should be done. You can check for a sqlsvr section in php_info.

I haven't done to much testing with this, but it says it has installed, so for now I will assume good. Also if you have sql server running on a different box, you may have to tweak your php interpreter settings in abyss from named pipes local to named pipes tcp/ip. Not sure as I'm just using a local version of sql express.

No comments: