MSSQL database connection - DF 2 (beta 2 and 3)

Good day,

I’ve been struggling to get DF Beta 2 (rel 2) to connect to a local MSSQL database (MSSQL Express 2008, R2, 64bit). My OS is Win 7 Enterprise 64bit.

I’ve followed almost all of the instructions on this forum, DF website and http://robsphp.blogspot.co.za/2012/09/how-to-install-microsofts-sql-server.html (which is really helpful). The problem is that DF indicated that it couldn’t load the sqlsrv dll’s when trying to create a MS SQL DB service. I ensured the dll’s are for the correct PHP version (5.5.28) and referenced in the PHP.ini file as described in numerous places, but still no joy.

I then decided to see if I could get a MS SQL service setup in DF 1.9.4 and low and behold after all the relevant edits (as mentioned above) I got it to work without any problem.

But, and here is the but. For a particular project we need to use AD/LDAP authentication and this is only available in DF 2 as I can see from various posts and DF promo’s. I saw this morning that DF 2 Beta 3 was made available and I’ve decided to give it a go. I’ve installed the Bitnami stack for 64bit on my computer and managed to get it up and running without a hassle. I then made all the relevant tweaks as per above and restarting Apache. I then tried to create the MS SQL DB service again but still got the same error message. When I look at the log-file I get the following error/warning:

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:/Bitnami/dreamfactory-2.0.beta-3/php/ext\php_pdo_sqlsrv_55_ts.dll’ - %1 is not a valid Win32 application.\r\n in Unknown on line 0

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:/Bitnami/dreamfactory-2.0.beta-3/php/ext\php_sqlsrv_55_ts.dll’ - %1 is not a valid Win32 application.\r\n in Unknown on line 0

I’m struggling to understand how this is possible since I’ve made sure to grab and copy the 64bit dll’s (extension=php_sqlsrv_55_ts.dll, extension=php_pdo_sqlsrv_55_ts.dll). I’ve even tried the 32bit versions still the same result.

Any assistance with this problem is highly appreciated.

Regards,
Pierre

Hi Pierre. It seems that the Microsoft supplied drivers do not work with 64bit PHP.
Yesterday I encountered this same problem and found some “unofficial” drivers that appear to work.
You can find these drivers here: http://robsphp.blogspot.com/2012/06/unofficial-microsoft-sql-server-driver.html
The steps for installing them are the same as the official drivers (they’re even named the same.)
I have only tested this with Windows 2008 R2.

Hi Drew,

Thank you for your quick response.

I’ve also downloaded these this morning and tested the 32bit versions, with no luck. I’ll give the 64bit’s a go and provide feedback.

Regards,
Pierre

Just some feedback.

I’ve copied the relevant 64bit dll’s provided from the link as suggested by Drew and managed to create the MS SQL service.

But now when I’m trying to view the schema no tables are loaded even if the refresh button is clicked. When trying to view the API’s for this service it reported - Unable to read api ‘mssql_pgwc’ from path http://xxx…/api/v2/api_docs/mssql_pgwc (server returned undefined)

Any ideas on this?

Just a note for anyone following this thread:

With the removal of the 64 bit Windows from the Bitnami installers page, there is no need to use the unofficial drivers referenced above. We DO NOT recommend using them. We ONLY recommend using the official sqlsrv drivers from Microsoft.

Also, @Pierredp I see you have an inquiry open directly with our support team. We will address the remainder of your SQL issue there. Once resolved you can post back here with the resolution.