PHP Access To An MSSQL Database From Debian Etch With ODBC And FreeTDS
This assumes you already have Apache2 and PHP5 set up properly on your system. My efforts to get this connection working were compiled from information found at http://www.unixodbc.org and http://www.freetds.org. These steps worked for me with an Apache2 web server with php5 running on Debian Etch stable in October of 2007. The SQL server is running Microsoft SQL 2005 on a Windows 2003 Server OS.
In these instructions I assume you’ve su’d to a root account. I also use joe as my editor so replace that with your editor of choice.