Jun 3, 2008

MSSQL + PHP in Ubuntu 8.04

Following comments to this post, I got MS SQL working with PHP.

$ apt-get install freetds-dev tdsodbc php5-sybase
$ nano /etc/odbcinst.ini
[FreeTDS]
Description = FreeTDS 0.61-5 Deb
Driver = /usr/lib/odbc/libtdsodbc.so
Setup = /usr/lib/odbc/libtdsS.so
FileUsage = 1
CPTimeout = 5
CPReuse = 5


$ nano /etc/odbc.ini
[Products]
Description = Products on The MSSQL Server
Driver = FreeTDS
Servername = FSData
Database = Products
Port = 1433

4 comments:

Aerik said...

So, is that all you had to do? Or did you have to compile from sources too?

thanks!
Aerik

sp said...

No, I didn't compile anything.

Warren Holmes said...

Will this work woth mssql() functions ?

sp said...

Yes, working mssql_* functions is the purpose of this whole configuration procedure.