Jump to content


Photo

PHP, IIS6, WinSVR2k3 - Connecting to MSSQL (PHP 5.4.8)


  • Please log in to reply
2 replies to this topic

#1 metcaelfe

metcaelfe

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 20 March 2013 - 11:19 PM

Howdy freaks,

 

I think I have hit a dead end with my attempts to connect to a MSSQL server (2008R2) using PHP (5.4.8).

I am running PHP through IIS using FastCGI.

 

I believe I have fulfilled the prerequisites but I either get an error informing Native Client 2012 required for driver, or call to unknown function (either mssql_connect() or sqlsr_connect() depending on driver in use - MS Version 2, or 3).

  1. PHP is functioning correctly via IIS - phpinfo() works
  2. Version 3.1? SQL extensions from Microsoft are installed (added to php.ini) (php_sqlsrv_54_nts.dll && php_pdo_sqlsrv_54_nts.dll) - I have also tried the Version 2.0 DLLs, but these seem not to work at all.
  3. SQL Native Client installed (v 10.0)

I think the problem is that I am using Windows Server 2003 (x86) and the SQL Native Client 2012 is not supported on 2k3... I cannot install it, only 2008R2 native client, so the 5.4 drivers from MS cannot be used.

---------------------------------

I guess I know what I think the answer is, but, can anyone tell me if what I am trying to achieve is even possible?


I assume no and that I will need to roll back to PHP 5.3 or something along those lines, I just want to confirm this prior to bursting a few more blood vessels in my eyes on this...

 

Any assistance will be greatly appreciated - if you need screens or more info at all, let me know :)

 

Thanks all!

 

Cael



#2 kicken

kicken

    Wiser? Not exactly.

  • Gurus
  • 1,827 posts
  • LocationBonita, FL

Posted 21 March 2013 - 02:35 AM

and the SQL Native Client 2012 is not supported on 2k3...

Have you tried installing the 2012 native client and had it fail? I do not see any note on the description for it suggesting it would not work. If it wont install, or is unstable, then I would say your diagnosis is probably accurate. Either stick with 5.3 or update to a supported OS.
Recycle your old CD's, don't trash them!
Did I help you out?  Feeling generous? I accept tips via Paypal or Bitcoin @ 14mDxaob8Jgdg52scDbvf3uaeR61tB2yC7

#3 metcaelfe

metcaelfe

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 02 April 2013 - 03:06 AM

Thanks for the reply kicken.

 

I did try to install the 2012 Native Client, but it will not install on Win 2k3.

 

Rolled back to 5.3 and I got it all sorted.

 

Cheers!






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

Cheap Linux VPS from $5
SSD Storage, 30 day Guarantee
1 TB of BW, 100% Network Uptime

AlphaBit.com