alunr's picture

One of my projects requires my app to talk to an MS SQL service from time to time.

How does one setup the module to allow this as I currently get:

Call to undefined function mssql_query()

Forum: 
Tags: 
Alon Swartz's picture

I just did a quick search and found the FreeTDS project,
It should be a simple install, not sure about configuration: apt-get update; apt-get install sqlrelay-freetds

FreeTDS is a set of libraries for Unix and Linux that allows your programs to natively talk to Microsoft SQL Server and Sybase databases.

Not sure if this is what you are looking for, maybe someone who has a similar configuration could chime in.

Hope the above helps.

alunr's picture

I think it's a case of having to enable the already existing MSSQL components.  It's all there in the INI but just not available as a function to my programs.

The whole site is coded usig this syntax so I really hope I can find a way of getting it installed!!!

I might try a vanilla install and creating a custom appliance instead.

alunr's picture

Okay, I've found this: http://www.howtoforge.com/installing_php_mssql_centos5.0

How do I go about doing the same thing on the LAMP Ubuntu appliance?

Alon Swartz's picture

I have not tried this myself, just a little googling...

php5-sybase might work (it provides the php5-mssql package), but i read there are a couple of issues, which might be solved by using pear to install the mdb2 mssql driver.

apt-get install php5-sybase php-pear
pear install --nodeps MDB2_Driver_mssql

If that doesn't work, you can try and rebuild the php package to include mssql support:

http://panthar.org/2006/06/15/php-with-mssql-on-ubuntu-606/
http://ubuntuforums.org/showthread.php?t=350269
http://www.lecentre.net/blog/archives/144
https://lists.ubuntu.com/archives/ubuntu-server-bugs/2009-May/012906.html

Let us know how it goes, with your help we might include mssql support in the upcoming release.
 

 

Add new comment