David Wallace
David Wallace

Reputation: 109

Connecting to MSSQL via php on Server 2012

I've been wanting to upgrade my windows web servers to 2012 but have hit a bottleneck. I currently use the microsoft sqlsrv driver to connect however Microsoft server 2012 does not support 32 bit ODBC connectors which that driver uses. I was going to upgrade to the 64 bit version of PHP however microsoft has not created a driver for that version.

What methods are supported on windows server 2012 to connect PHP 5.4+ to Microsoft SQL 2008+?

Upvotes: 1

Views: 1381

Answers (1)

Michael Chudinov
Michael Chudinov

Reputation: 2958

Microsoft php sqlsrv driver for php 5.4 needs SQL Server Native Client for SQL server. And it works well with SQL server 2012 x64 and even 2014 x64.

Official php 5.4 divers can be downloaded from here http://www.microsoft.com/en-us/download/details.aspx?id=20098

Read this thread about drivers for php 5.5 http://sqlsrvphp.codeplex.com/discussions/441706

There is a download link there to unofficial php 5.5 drivers. Someone with nick wshmstr published drivers recompiled for php 5.5. I use them in production for a year now with SQL server 2012 and 2014 without any problems. All these drivers are for Windows 2008, 2012 server x86/64 and for x86 php only.

Upvotes: 2

Related Questions