WAMPServer + MS-SQL = ERROR
Posted by: rackycz (193.179.134.---)
Date: November 04, 2010 08:28AM

Hello. This topic is heavily discussed in all forums, but I did not find any solution. The problem is simple:
WAMP does not support MS-SQL (in my case version 2000).
(I use Win XP, Wamp 2.0 = PHP 5.3.0 + Apache 2.2.11 + MySQL 5.1.36 )

I did this:

Uncommented lines (in all php.ini files) that contain:
extension=php_mssql.dll
extension=php_pdo_mssql.dll

Clicked Wamp icon and in menu "PHP / PHP extensions" checked options
-php_mssql
-php_pdo_mssql

Restarted Wamp.

I tried to download some ms-sql driver by MS, but it did not work:
[www.microsoft.com]

I connected to MS SQL in the past so I know, that PHP can do this. But now when I try to connect to ms-sql i get these errors:
From pure PHP: Call to undefined function mssql_connect()
From PHP framework Yii: could not find driver

I need this to work, but I cant figure it out. Can any one help please? I need clear advice, not just "download xyz, configure it, compile it etc.."
Is there some easy solution that can be done using a few mouse clicks, not by compiling and changing ini files?

I also saw following page but it didnt help. It wants me to compile something, which is too complicated for me sad smiley
[cz.php.net]

Thank your very much in advance..

Options: ReplyQuote
Re: WAMPServer + MS-SQL = ERROR
Posted by: stevenmartin99 (---.b-ras2.blp.dublin.eircom.net)
Date: November 04, 2010 08:34AM

how did you edit the php.ini

there is many php.ini files in wmamp...


u have to left click wamp> php> php.ini


this will be the correct file (phpforapache.ini)

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: WAMPServer + MS-SQL = ERROR
Posted by: rackycz (193.179.134.---)
Date: November 04, 2010 09:49AM

I have only 2 php.ini files. I changed both of them.
The one that is opened via wamp menu the one in Apache/bin folder
Second one is in php5.3.0 folder

Options: ReplyQuote
Re: WAMPServer + MS-SQL = ERROR
Posted by: rackycz (193.179.134.---)
Date: November 04, 2010 09:57AM

I also tried this, but it did not work neither
[forum.wampserver.com]

Options: ReplyQuote
Re: WAMPServer + MS-SQL = ERROR
Posted by: stevenmartin99 (---.b-ras2.blp.dublin.eircom.net)
Date: November 04, 2010 10:06AM

did you check phpinfo() to see if MSSQL is loaded?

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: WAMPServer + MS-SQL = ERROR
Posted by: rackycz (193.179.134.---)
Date: November 04, 2010 10:25AM

I checked PDO section of php info.
PDO drivers = sqlsrv, mysql, sqlite

mssql is not mentioned in the whole page

Options: ReplyQuote
Re: WAMPServer + MS-SQL = ERROR
Posted by: rackycz (193.179.134.---)
Date: November 04, 2010 03:17PM

Well, I solved it finally. Only one thing is important: DO NOT USE PHP 5.3 and above if you want to work with MS SQL. I downloaded XAMPP 1.7.0, it has PHP 5.2.8 and everything works well.



Edited 1 time(s). Last edit at 11/04/2010 05:08PM by yfastud.

Options: ReplyQuote
Re: WAMPServer + MS-SQL = ERROR
Posted by: yfastud (Moderator)
Date: November 04, 2010 05:09PM

It's fine when you decided to chose xampp instead go w/ older wampserver that has those script versions but please dont post their links in this forums. Thanks winking smiley

Have fun,

FREE One A Day
FREE Photo
FREE Games
FREE Websites
FREE Portable GPS
FREE WAMP Guides

Options: ReplyQuote
Re: WAMPServer + MS-SQL = ERROR
Posted by: stevenmartin99 (---.251.255.12.threembb.ie)
Date: November 04, 2010 09:29PM

And u can use the addon menu above to get other versions of php

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: WAMPServer + MS-SQL = ERROR
Posted by: rackycz (193.179.134.---)
Date: November 05, 2010 08:13AM

WAMP allows me to download older versions? I didnt know that so I used XAMPP. They have link to old versions, WAMP doesnt. Anf if I install 2 WAMPs paralelly, will it work ok? Where can I get WAMP with PHP 5.2 ?

Options: ReplyQuote
Re: WAMPServer + MS-SQL = ERROR
Posted by: stevenmartin99 (---.251.255.13.threembb.ie)
Date: November 05, 2010 08:17AM

On the addon menu on the menu bar of this site


Or left click wamp> php> version> get more

Xammp doesn't have this smiling smiley

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: WAMPServer + MS-SQL = ERROR
Posted by: gaetgodi (---.dsl.bell.ca)
Date: September 14, 2011 03:26PM

thank you for this, I downloaded a previous version of PHP, installed it and my mssql pdo works fine.

Options: ReplyQuote


Sorry, only registered users may post in this forum.